Completed
Pull Request — master (#5259)
by Björn
21:44
created
settings/templates/personal.php 1 patch
Spacing   +58 added lines, -58 removed lines patch added patch discarded remove patch
@@ -10,10 +10,10 @@  discard block
 block discarded – undo
10 10
 
11 11
 <div id="app-navigation">
12 12
 	<ul class="with-icon">
13
-	<?php foreach($_['forms'] as $form) {
13
+	<?php foreach ($_['forms'] as $form) {
14 14
 		if (isset($form['anchor'])) {
15
-			$anchor = '#' . $form['anchor'];
16
-			$class = 'nav-icon-' . $form['anchor'];
15
+			$anchor = '#'.$form['anchor'];
16
+			$class = 'nav-icon-'.$form['anchor'];
17 17
 			$sectionName = $form['section-name'];
18 18
 			print_unescaped(sprintf("<li><a href='%s' class='%s'>%s</a></li>", \OCP\Util::sanitizeHTML($anchor),
19 19
 			\OCP\Util::sanitizeHTML($class), \OCP\Util::sanitizeHTML($sectionName)));
@@ -25,15 +25,15 @@  discard block
 block discarded – undo
25 25
 <div id="app-content">
26 26
 
27 27
 <div id="quota" class="section">
28
-	<div style="width:<?php p($_['usage_relative']);?>%"
29
-		<?php if($_['usage_relative'] > 80): ?> class="quota-warning" <?php endif; ?>>
28
+	<div style="width:<?php p($_['usage_relative']); ?>%"
29
+		<?php if ($_['usage_relative'] > 80): ?> class="quota-warning" <?php endif; ?>>
30 30
 		<p id="quotatext">
31 31
 			<?php if ($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?>
32 32
 				<?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong>',
33
-					[$_['usage'], $_['total_space']]));?>
33
+					[$_['usage'], $_['total_space']])); ?>
34 34
 			<?php else: ?>
35 35
 				<?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong> (<strong>%s %%</strong>)',
36
-					[$_['usage'], $_['total_space'],  $_['usage_relative']]));?>
36
+					[$_['usage'], $_['total_space'], $_['usage_relative']])); ?>
37 37
 			<?php endif ?>
38 38
 		</p>
39 39
 	</div>
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
 			</div>
68 68
 		</div>
69 69
 		<span class="icon-checkmark hidden"/>
70
-		<?php if($_['lookupServerUploadEnabled']) { ?>
70
+		<?php if ($_['lookupServerUploadEnabled']) { ?>
71 71
 		<input type="hidden" id="avatarscope" value="<?php p($_['avatarScope']) ?>">
72 72
 		<?php } ?>
73 73
 	</form>
@@ -81,14 +81,14 @@  discard block
 block discarded – undo
81 81
 				<span class="icon-password"/>
82 82
 			</h2>
83 83
 			<input type="text" id="displayname" name="displayname"
84
-				<?php if(!$_['displayNameChangeSupported']) { print_unescaped('class="hidden"'); } ?>
84
+				<?php if (!$_['displayNameChangeSupported']) { print_unescaped('class="hidden"'); } ?>
85 85
 				value="<?php p($_['displayName']) ?>"
86 86
 				autocomplete="on" autocapitalize="none" autocorrect="off" />
87
-			<?php if(!$_['displayNameChangeSupported']) { ?>
88
-				<span><?php if(isset($_['displayName']) && !empty($_['displayName'])) { p($_['displayName']); } else { p($l->t('No display name set')); } ?></span>
87
+			<?php if (!$_['displayNameChangeSupported']) { ?>
88
+				<span><?php if (isset($_['displayName']) && !empty($_['displayName'])) { p($_['displayName']); } else { p($l->t('No display name set')); } ?></span>
89 89
 			<?php } ?>
90 90
 			<span class="icon-checkmark hidden"/>
91
-			<?php if($_['lookupServerUploadEnabled']) { ?>
91
+			<?php if ($_['lookupServerUploadEnabled']) { ?>
92 92
 			<input type="hidden" id="displaynamescope" value="<?php p($_['displayNameScope']) ?>">
93 93
 			<?php } ?>
94 94
 		</form>
@@ -99,10 +99,10 @@  discard block
 block discarded – undo
99 99
 				<label for="email"><?php p($l->t('Email')); ?></label>
100 100
 				<span class="icon-password"/>
101 101
 			</h2>
102
-			<div class="verify <?php if ($_['email'] === ''  || $_['emailScope'] !== 'public') p('hidden'); ?>">
102
+			<div class="verify <?php if ($_['email'] === '' || $_['emailScope'] !== 'public') p('hidden'); ?>">
103 103
 				<img id="verify-email" title="<?php p($_['emailMessage']); ?>" data-status="<?php p($_['emailVerification']) ?>" src="
104 104
 				<?php
105
-				switch($_['emailVerification']) {
105
+				switch ($_['emailVerification']) {
106 106
 					case \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS:
107 107
 						p(image_path('core', 'actions/verifying.svg'));
108 108
 						break;
@@ -115,23 +115,23 @@  discard block
 block discarded – undo
115 115
 				?>">
116 116
 			</div>
117 117
 			<input type="email" name="email" id="email" value="<?php p($_['email']); ?>"
118
-				<?php if(!$_['displayNameChangeSupported']) { print_unescaped('class="hidden"'); } ?>
118
+				<?php if (!$_['displayNameChangeSupported']) { print_unescaped('class="hidden"'); } ?>
119 119
 				placeholder="<?php p($l->t('Your email address')); ?>"
120 120
 				autocomplete="on" autocapitalize="none" autocorrect="off" />
121
-			<?php if(!$_['displayNameChangeSupported']) { ?>
122
-				<span><?php if(isset($_['email']) && !empty($_['email'])) { p($_['email']); } else { p($l->t('No email address set')); }?></span>
121
+			<?php if (!$_['displayNameChangeSupported']) { ?>
122
+				<span><?php if (isset($_['email']) && !empty($_['email'])) { p($_['email']); } else { p($l->t('No email address set')); }?></span>
123 123
 			<?php } ?>
124
-			<?php if($_['displayNameChangeSupported']) { ?>
124
+			<?php if ($_['displayNameChangeSupported']) { ?>
125 125
 				<br />
126 126
 				<em><?php p($l->t('For password reset and notifications')); ?></em>
127 127
 			<?php } ?>
128 128
 			<span class="icon-checkmark hidden"/>
129
-			<?php if($_['lookupServerUploadEnabled']) { ?>
129
+			<?php if ($_['lookupServerUploadEnabled']) { ?>
130 130
 			<input type="hidden" id="emailscope" value="<?php p($_['emailScope']) ?>">
131 131
 			<?php } ?>
132 132
 		</form>
133 133
 	</div>
134
-	<?php if($_['lookupServerUploadEnabled']) { ?>
134
+	<?php if ($_['lookupServerUploadEnabled']) { ?>
135 135
 	<div class="personal-settings-setting-box">
136 136
 		<form id="phoneform" class="section">
137 137
 			<h2>
@@ -166,10 +166,10 @@  discard block
 block discarded – undo
166 166
 				<label for="website"><?php p($l->t('Website')); ?></label>
167 167
 				<span class="icon-password"/>
168 168
 			</h2>
169
-			<div class="verify <?php if ($_['website'] === ''  || $_['websiteScope'] !== 'public') p('hidden'); ?>">
169
+			<div class="verify <?php if ($_['website'] === '' || $_['websiteScope'] !== 'public') p('hidden'); ?>">
170 170
 				<img id="verify-website" title="<?php p($_['websiteMessage']); ?>" data-status="<?php p($_['websiteVerification']) ?>" src="
171 171
 				<?php
172
-				switch($_['websiteVerification']) {
172
+				switch ($_['websiteVerification']) {
173 173
 					case \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS:
174 174
 						p(image_path('core', 'actions/verifying.svg'));
175 175
 						break;
@@ -180,13 +180,13 @@  discard block
 block discarded – undo
180 180
 						p(image_path('core', 'actions/verify.svg'));
181 181
 				}
182 182
 				?>"
183
-				<?php if($_['websiteVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['websiteVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?>
183
+				<?php if ($_['websiteVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['websiteVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?>
184 184
 				>
185 185
 				<div class="verification-dialog popovermenu bubble menu">
186 186
 					<div class="verification-dialog-content">
187 187
 						<p class="explainVerification"></p>
188 188
 						<p class="verificationCode"></p>
189
-						<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));?></p>
189
+						<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.')); ?></p>
190 190
 					</div>
191 191
 				</div>
192 192
 			</div>
@@ -203,10 +203,10 @@  discard block
 block discarded – undo
203 203
 				<label for="twitter"><?php p($l->t('Twitter')); ?></label>
204 204
 				<span class="icon-password"/>
205 205
 			</h2>
206
-			<div class="verify <?php if ($_['twitter'] === ''  || $_['twitterScope'] !== 'public') p('hidden'); ?>">
206
+			<div class="verify <?php if ($_['twitter'] === '' || $_['twitterScope'] !== 'public') p('hidden'); ?>">
207 207
 				<img id="verify-twitter" title="<?php p($_['twitterMessage']); ?>" data-status="<?php p($_['twitterVerification']) ?>" src="
208 208
 				<?php
209
-				switch($_['twitterVerification']) {
209
+				switch ($_['twitterVerification']) {
210 210
 					case \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS:
211 211
 						p(image_path('core', 'actions/verifying.svg'));
212 212
 						break;
@@ -217,13 +217,13 @@  discard block
 block discarded – undo
217 217
 						p(image_path('core', 'actions/verify.svg'));
218 218
 				}
219 219
 				?>"
220
-				<?php if($_['twitterVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['twitterVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?>
220
+				<?php if ($_['twitterVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['twitterVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?>
221 221
 				>
222 222
 				<div class="verification-dialog popovermenu bubble menu">
223 223
 					<div class="verification-dialog-content">
224 224
 						<p class="explainVerification"></p>
225 225
 						<p class="verificationCode"></p>
226
-						<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));?></p>
226
+						<p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.')); ?></p>
227 227
 					</div>
228 228
 				</div>
229 229
 			</div>
@@ -250,19 +250,19 @@  discard block
 block discarded – undo
250 250
 <?php endif; ?>
251 251
 
252 252
 <?php
253
-if($_['passwordChangeSupported']) {
253
+if ($_['passwordChangeSupported']) {
254 254
 	script('jquery-showpassword');
255 255
 ?>
256 256
 <form id="passwordform" class="section">
257
-	<h2 class="inlineblock"><?php p($l->t('Password'));?></h2>
257
+	<h2 class="inlineblock"><?php p($l->t('Password')); ?></h2>
258 258
 	<div id="password-error-msg" class="msg success inlineblock" style="display: none;">Saved</div>
259 259
 	<br>
260 260
 	<label for="pass1" class="hidden-visually"><?php p($l->t('Current password')); ?>: </label>
261 261
 	<input type="password" id="pass1" name="oldpassword"
262
-		placeholder="<?php p($l->t('Current password'));?>"
262
+		placeholder="<?php p($l->t('Current password')); ?>"
263 263
 		autocomplete="off" autocapitalize="none" autocorrect="off" />
264 264
 	<div class="personal-show-container">
265
-		<label for="pass2" class="hidden-visually"><?php p($l->t('New password'));?>: </label>
265
+		<label for="pass2" class="hidden-visually"><?php p($l->t('New password')); ?>: </label>
266 266
 		<input type="password" id="pass2" name="newpassword"
267 267
 			placeholder="<?php p($l->t('New password')); ?>"
268 268
 			data-typetoggle="#personal-show"
@@ -278,44 +278,44 @@  discard block
 block discarded – undo
278 278
 
279 279
 <form id="language" class="section">
280 280
 	<h2>
281
-		<label for="languageinput"><?php p($l->t('Language'));?></label>
281
+		<label for="languageinput"><?php p($l->t('Language')); ?></label>
282 282
 	</h2>
283
-	<select id="languageinput" name="lang" data-placeholder="<?php p($l->t('Language'));?>">
284
-		<option value="<?php p($_['activelanguage']['code']);?>">
285
-			<?php p($_['activelanguage']['name']);?>
283
+	<select id="languageinput" name="lang" data-placeholder="<?php p($l->t('Language')); ?>">
284
+		<option value="<?php p($_['activelanguage']['code']); ?>">
285
+			<?php p($_['activelanguage']['name']); ?>
286 286
 		</option>
287
-		<?php foreach($_['commonlanguages'] as $language):?>
288
-			<option value="<?php p($language['code']);?>">
289
-				<?php p($language['name']);?>
287
+		<?php foreach ($_['commonlanguages'] as $language):?>
288
+			<option value="<?php p($language['code']); ?>">
289
+				<?php p($language['name']); ?>
290 290
 			</option>
291
-		<?php endforeach;?>
291
+		<?php endforeach; ?>
292 292
 		<optgroup label="––––––––––"></optgroup>
293
-		<?php foreach($_['languages'] as $language):?>
294
-			<option value="<?php p($language['code']);?>">
295
-				<?php p($language['name']);?>
293
+		<?php foreach ($_['languages'] as $language):?>
294
+			<option value="<?php p($language['code']); ?>">
295
+				<?php p($language['name']); ?>
296 296
 			</option>
297
-		<?php endforeach;?>
297
+		<?php endforeach; ?>
298 298
 	</select>
299 299
 	<a href="https://www.transifex.com/nextcloud/nextcloud/"
300 300
 		target="_blank" rel="noreferrer">
301
-		<em><?php p($l->t('Help translate'));?></em>
301
+		<em><?php p($l->t('Help translate')); ?></em>
302 302
 	</a>
303 303
 </form>
304 304
 
305 305
 
306 306
 <div id="clientsbox" class="section clientsbox">
307
-	<h2><?php p($l->t('Get the apps to sync your files'));?></h2>
307
+	<h2><?php p($l->t('Get the apps to sync your files')); ?></h2>
308 308
 	<a href="<?php p($_['clients']['desktop']); ?>" rel="noreferrer" target="_blank">
309 309
 		<img src="<?php print_unescaped(image_path('core', 'desktopapp.svg')); ?>"
310
-			 alt="<?php p($l->t('Desktop client'));?>" />
310
+			 alt="<?php p($l->t('Desktop client')); ?>" />
311 311
 	</a>
312 312
 	<a href="<?php p($_['clients']['android']); ?>" rel="noreferrer" target="_blank">
313 313
 		<img src="<?php print_unescaped(image_path('core', 'googleplay.png')); ?>"
314
-			 alt="<?php p($l->t('Android app'));?>" />
314
+			 alt="<?php p($l->t('Android app')); ?>" />
315 315
 	</a>
316 316
 	<a href="<?php p($_['clients']['ios']); ?>" rel="noreferrer" target="_blank">
317 317
 		<img src="<?php print_unescaped(image_path('core', 'appstore.svg')); ?>"
318
-			 alt="<?php p($l->t('iOS app'));?>" />
318
+			 alt="<?php p($l->t('iOS app')); ?>" />
319 319
 	</a>
320 320
 
321 321
 		<p>
@@ -331,19 +331,19 @@  discard block
 block discarded – undo
331 331
 				$l->t('If you want to support the project {contributeopen}join development{linkclose} or {contributeopen}spread the word{linkclose}!'))); ?>
332 332
 		</p>
333 333
 
334
-	<?php if(OC_APP::isEnabled('firstrunwizard')) {?>
335
-		<p><a class="button" href="#" id="showWizard"><?php p($l->t('Show First Run Wizard again'));?></a></p>
334
+	<?php if (OC_APP::isEnabled('firstrunwizard')) {?>
335
+		<p><a class="button" href="#" id="showWizard"><?php p($l->t('Show First Run Wizard again')); ?></a></p>
336 336
 	<?php }?>
337 337
 </div>
338 338
 
339 339
 <div id="sessions" class="section">
340
-	<h2><?php p($l->t('Sessions'));?></h2>
341
-	<p class="settings-hint hidden-when-empty"><?php p($l->t('Web, desktop and mobile clients currently logged in to your account.'));?></p>
340
+	<h2><?php p($l->t('Sessions')); ?></h2>
341
+	<p class="settings-hint hidden-when-empty"><?php p($l->t('Web, desktop and mobile clients currently logged in to your account.')); ?></p>
342 342
 	<table class="icon-loading">
343 343
 		<thead class="token-list-header">
344 344
 			<tr>
345
-				<th><?php p($l->t('Device'));?></th>
346
-				<th><?php p($l->t('Last activity'));?></th>
345
+				<th><?php p($l->t('Device')); ?></th>
346
+				<th><?php p($l->t('Last activity')); ?></th>
347 347
 				<th></th>
348 348
 			</tr>
349 349
 		</thead>
@@ -372,14 +372,14 @@  discard block
 block discarded – undo
372 372
 	</div>
373 373
 </div>
374 374
 
375
-<?php foreach($_['forms'] as $form) {
375
+<?php foreach ($_['forms'] as $form) {
376 376
 	if (isset($form['form'])) {?>
377
-	<div id="<?php isset($form['anchor']) ? p($form['anchor']) : p('');?>"><?php print_unescaped($form['form']);?></div>
377
+	<div id="<?php isset($form['anchor']) ? p($form['anchor']) : p(''); ?>"><?php print_unescaped($form['form']); ?></div>
378 378
 	<?php }
379 379
 };?>
380 380
 
381 381
 <div class="section">
382
-	<h2><?php p($l->t('Version'));?></h2>
382
+	<h2><?php p($l->t('Version')); ?></h2>
383 383
 	<p><a href="<?php print_unescaped($theme->getBaseUrl()); ?>" target="_blank"><?php p($theme->getTitle()); ?></a> <?php p(OC_Util::getHumanVersion()) ?></p>
384 384
 	<p><?php include('settings.development.notice.php'); ?></p>
385 385
 </div>
Please login to merge, or discard this patch.