@@ -46,9 +46,12 @@ discard block |
||
46 | 46 | <?php if ($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?> |
47 | 47 | <?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong>', |
48 | 48 | [$_['usage'], $_['total_space']]));?> |
49 | - <?php else: ?> |
|
49 | + <?php else { |
|
50 | + : ?> |
|
50 | 51 | <?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong> (<strong>%s %%</strong>)', |
51 | - [$_['usage'], $_['total_space'], $_['usage_relative']]));?> |
|
52 | + [$_['usage'], $_['total_space'], $_['usage_relative']])); |
|
53 | +} |
|
54 | +?> |
|
52 | 55 | <?php endif ?> |
53 | 56 | </p> |
54 | 57 | </div> |
@@ -57,9 +60,12 @@ discard block |
||
57 | 60 | <?php if ($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?> |
58 | 61 | <?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong>', |
59 | 62 | [$_['usage'], $_['total_space']]));?> |
60 | - <?php else: ?> |
|
63 | + <?php else { |
|
64 | + : ?> |
|
61 | 65 | <?php print_unescaped($l->t('You are using <strong>%s</strong> of <strong>%s</strong> (<strong>%s %%</strong>)', |
62 | - [$_['usage'], $_['total_space'], $_['usage_relative']]));?> |
|
66 | + [$_['usage'], $_['total_space'], $_['usage_relative']])); |
|
67 | +} |
|
68 | +?> |
|
63 | 69 | <?php endif ?> |
64 | 70 | </p> |
65 | 71 | </div> |
@@ -83,8 +89,11 @@ discard block |
||
83 | 89 | <div class="hidden button icon-delete svg" id="removeavatar" title="<?php p($l->t('Remove image')); ?>"></div> |
84 | 90 | <input type="file" name="files[]" id="uploadavatar" class="hiddenuploadfield"> |
85 | 91 | <p><em><?php p($l->t('png or jpg, max. 20 MB')); ?></em></p> |
86 | - <?php else: ?> |
|
87 | - <?php p($l->t('Picture provided by original account')); ?> |
|
92 | + <?php else { |
|
93 | + : ?> |
|
94 | + <?php p($l->t('Picture provided by original account')); |
|
95 | +} |
|
96 | +?> |
|
88 | 97 | <?php endif; ?> |
89 | 98 | </div> |
90 | 99 | |
@@ -133,7 +142,10 @@ discard block |
||
133 | 142 | <span class="icon-triangle-s"></span> |
134 | 143 | </span> |
135 | 144 | </h2> |
136 | - <div class="verify <?php if ($_['email'] === '' || $_['emailScope'] !== 'public') p('hidden'); ?>"> |
|
145 | + <div class="verify <?php if ($_['email'] === '' || $_['emailScope'] !== 'public') { |
|
146 | + p('hidden'); |
|
147 | +} |
|
148 | +?>"> |
|
137 | 149 | <img id="verify-email" title="<?php p($_['emailMessage']); ?>" data-status="<?php p($_['emailVerification']) ?>" src=" |
138 | 150 | <?php |
139 | 151 | switch($_['emailVerification']) { |
@@ -174,7 +186,10 @@ discard block |
||
174 | 186 | <span class="icon-triangle-s"></span> |
175 | 187 | </span> |
176 | 188 | </h2> |
177 | - <input type="tel" id="phone" name="phone" <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"'); ?> |
|
189 | + <input type="tel" id="phone" name="phone" <?php if(!$_['lookupServerUploadEnabled']) { |
|
190 | + print_unescaped('disabled="1"'); |
|
191 | +} |
|
192 | +?> |
|
178 | 193 | value="<?php p($_['phone']) ?>" |
179 | 194 | placeholder="<?php p($l->t('Your phone number')); ?>" |
180 | 195 | autocomplete="on" autocapitalize="none" autocorrect="off" /> |
@@ -194,7 +209,10 @@ discard block |
||
194 | 209 | <span class="icon-triangle-s"></span> |
195 | 210 | </span> |
196 | 211 | </h2> |
197 | - <input type="text" id="address" name="address" <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"'); ?> |
|
212 | + <input type="text" id="address" name="address" <?php if(!$_['lookupServerUploadEnabled']) { |
|
213 | + print_unescaped('disabled="1"'); |
|
214 | +} |
|
215 | +?> |
|
198 | 216 | placeholder="<?php p($l->t('Your postal address')); ?>" |
199 | 217 | value="<?php p($_['address']) ?>" |
200 | 218 | autocomplete="on" autocapitalize="none" autocorrect="off" /> |
@@ -215,7 +233,10 @@ discard block |
||
215 | 233 | </span> |
216 | 234 | </h2> |
217 | 235 | <?php if($_['lookupServerUploadEnabled']) { ?> |
218 | - <div class="verify <?php if ($_['website'] === '' || $_['websiteScope'] !== 'public') p('hidden'); ?>"> |
|
236 | + <div class="verify <?php if ($_['website'] === '' || $_['websiteScope'] !== 'public') { |
|
237 | + p('hidden'); |
|
238 | +} |
|
239 | +?>"> |
|
219 | 240 | <img id="verify-website" title="<?php p($_['websiteMessage']); ?>" data-status="<?php p($_['websiteVerification']) ?>" src=" |
220 | 241 | <?php |
221 | 242 | switch($_['websiteVerification']) { |
@@ -229,13 +250,16 @@ discard block |
||
229 | 250 | p(image_path('core', 'actions/verify.svg')); |
230 | 251 | } |
231 | 252 | ?>" |
232 | - <?php if($_['websiteVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['websiteVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?> |
|
253 | + <?php if($_['websiteVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['websiteVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) { |
|
254 | + print_unescaped(' class="verify-action"') ?> |
|
233 | 255 | > |
234 | 256 | <div class="verification-dialog popovermenu bubble menu"> |
235 | 257 | <div class="verification-dialog-content"> |
236 | 258 | <p class="explainVerification"></p> |
237 | 259 | <p class="verificationCode"></p> |
238 | - <p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));?></p> |
|
260 | + <p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.')); |
|
261 | +} |
|
262 | +?></p> |
|
239 | 263 | </div> |
240 | 264 | </div> |
241 | 265 | </div> |
@@ -243,7 +267,10 @@ discard block |
||
243 | 267 | <input type="url" name="website" id="website" value="<?php p($_['website']); ?>" |
244 | 268 | placeholder="<?php p($l->t('Link https://…')); ?>" |
245 | 269 | autocomplete="on" autocapitalize="none" autocorrect="off" |
246 | - <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"'); ?> |
|
270 | + <?php if(!$_['lookupServerUploadEnabled']) { |
|
271 | + print_unescaped('disabled="1"'); |
|
272 | +} |
|
273 | +?> |
|
247 | 274 | /> |
248 | 275 | <span class="icon-checkmark hidden"></span> |
249 | 276 | <?php if($_['lookupServerUploadEnabled']) { ?> |
@@ -262,7 +289,10 @@ discard block |
||
262 | 289 | </span> |
263 | 290 | </h2> |
264 | 291 | <?php if($_['lookupServerUploadEnabled']) { ?> |
265 | - <div class="verify <?php if ($_['twitter'] === '' || $_['twitterScope'] !== 'public') p('hidden'); ?>"> |
|
292 | + <div class="verify <?php if ($_['twitter'] === '' || $_['twitterScope'] !== 'public') { |
|
293 | + p('hidden'); |
|
294 | +} |
|
295 | +?>"> |
|
266 | 296 | <img id="verify-twitter" title="<?php p($_['twitterMessage']); ?>" data-status="<?php p($_['twitterVerification']) ?>" src=" |
267 | 297 | <?php |
268 | 298 | switch($_['twitterVerification']) { |
@@ -276,13 +306,16 @@ discard block |
||
276 | 306 | p(image_path('core', 'actions/verify.svg')); |
277 | 307 | } |
278 | 308 | ?>" |
279 | - <?php if($_['twitterVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['twitterVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) print_unescaped(' class="verify-action"') ?> |
|
309 | + <?php if($_['twitterVerification'] === \OC\Accounts\AccountManager::VERIFICATION_IN_PROGRESS || $_['twitterVerification'] === \OC\Accounts\AccountManager::NOT_VERIFIED) { |
|
310 | + print_unescaped(' class="verify-action"') ?> |
|
280 | 311 | > |
281 | 312 | <div class="verification-dialog popovermenu bubble menu"> |
282 | 313 | <div class="verification-dialog-content"> |
283 | 314 | <p class="explainVerification"></p> |
284 | 315 | <p class="verificationCode"></p> |
285 | - <p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.'));?></p> |
|
316 | + <p><?php p($l->t('It can take up to 24 hours before the account is displayed as verified.')); |
|
317 | +} |
|
318 | +?></p> |
|
286 | 319 | </div> |
287 | 320 | </div> |
288 | 321 | </div> |
@@ -290,7 +323,10 @@ discard block |
||
290 | 323 | <input type="text" name="twitter" id="twitter" value="<?php p($_['twitter']); ?>" |
291 | 324 | placeholder="<?php p($l->t('Twitter handle @…')); ?>" |
292 | 325 | autocomplete="on" autocapitalize="none" autocorrect="off" |
293 | - <?php if(!$_['lookupServerUploadEnabled']) print_unescaped('disabled="1"'); ?> |
|
326 | + <?php if(!$_['lookupServerUploadEnabled']) { |
|
327 | + print_unescaped('disabled="1"'); |
|
328 | +} |
|
329 | +?> |
|
294 | 330 | /> |
295 | 331 | <span class="icon-checkmark hidden"></span> |
296 | 332 | <?php if($_['lookupServerUploadEnabled']) { ?> |
@@ -48,21 +48,30 @@ |
||
48 | 48 | <div id="userlistoptions"> |
49 | 49 | <p> |
50 | 50 | <input type="checkbox" name="StorageLocation" value="StorageLocation" id="CheckboxStorageLocation" |
51 | - class="checkbox" <?php if ($_['show_storage_location'] === 'true') print_unescaped('checked="checked"'); ?> /> |
|
51 | + class="checkbox" <?php if ($_['show_storage_location'] === 'true') { |
|
52 | + print_unescaped('checked="checked"'); |
|
53 | +} |
|
54 | +?> /> |
|
52 | 55 | <label for="CheckboxStorageLocation"> |
53 | 56 | <?php p($l->t('Show storage location')) ?> |
54 | 57 | </label> |
55 | 58 | </p> |
56 | 59 | <p> |
57 | 60 | <input type="checkbox" name="UserBackend" value="UserBackend" id="CheckboxUserBackend" |
58 | - class="checkbox" <?php if ($_['show_backend'] === 'true') print_unescaped('checked="checked"'); ?> /> |
|
61 | + class="checkbox" <?php if ($_['show_backend'] === 'true') { |
|
62 | + print_unescaped('checked="checked"'); |
|
63 | +} |
|
64 | +?> /> |
|
59 | 65 | <label for="CheckboxUserBackend"> |
60 | 66 | <?php p($l->t('Show user backend')) ?> |
61 | 67 | </label> |
62 | 68 | </p> |
63 | 69 | <p> |
64 | 70 | <input type="checkbox" name="LastLogin" value="LastLogin" id="CheckboxLastLogin" |
65 | - class="checkbox" <?php if ($_['show_last_login'] === 'true') print_unescaped('checked="checked"'); ?> /> |
|
71 | + class="checkbox" <?php if ($_['show_last_login'] === 'true') { |
|
72 | + print_unescaped('checked="checked"'); |
|
73 | +} |
|
74 | +?> /> |
|
66 | 75 | <label for="CheckboxLastLogin"> |
67 | 76 | <?php p($l->t('Show last login')) ?> |
68 | 77 | </label> |
@@ -94,7 +94,10 @@ discard block |
||
94 | 94 | |
95 | 95 | <form data-can-create="<?php echo $canCreateMounts?'true':'false' ?>" id="files_external" class="section" data-encryption-enabled="<?php echo $_['encryptionEnabled']?'true': 'false'; ?>"> |
96 | 96 | <h2 data-anchor-name="external-storage"><?php p($l->t('External storages')); ?></h2> |
97 | - <?php if (isset($_['dependencies']) and ($_['dependencies'] !== '') and $canCreateMounts) print_unescaped(''.$_['dependencies'].''); ?> |
|
97 | + <?php if (isset($_['dependencies']) and ($_['dependencies'] !== '') and $canCreateMounts) { |
|
98 | + print_unescaped(''.$_['dependencies'].''); |
|
99 | +} |
|
100 | +?> |
|
98 | 101 | <table id="externalStorage" class="grid" data-admin='<?php print_unescaped(json_encode($_['visibilityType'] === BackendService::VISIBILITY_ADMIN)); ?>'> |
99 | 102 | <thead> |
100 | 103 | <tr> |
@@ -103,7 +106,10 @@ discard block |
||
103 | 106 | <th><?php p($l->t('External storage')); ?></th> |
104 | 107 | <th><?php p($l->t('Authentication')); ?></th> |
105 | 108 | <th><?php p($l->t('Configuration')); ?></th> |
106 | - <?php if ($_['visibilityType'] === BackendService::VISIBILITY_ADMIN) print_unescaped('<th>'.$l->t('Available for').'</th>'); ?> |
|
109 | + <?php if ($_['visibilityType'] === BackendService::VISIBILITY_ADMIN) { |
|
110 | + print_unescaped('<th>'.$l->t('Available for').'</th>'); |
|
111 | +} |
|
112 | +?> |
|
107 | 113 | <th> </th> |
108 | 114 | <th> </th> |
109 | 115 | <th> </th> |
@@ -136,7 +142,10 @@ discard block |
||
136 | 142 | }); |
137 | 143 | ?> |
138 | 144 | <?php foreach ($sortedBackends as $backend): ?> |
139 | - <?php if ($backend->getDeprecateTo()) continue; // ignore deprecated backends ?> |
|
145 | + <?php if ($backend->getDeprecateTo()) { |
|
146 | + continue; |
|
147 | +} |
|
148 | +// ignore deprecated backends ?> |
|
140 | 149 | <option value="<?php p($backend->getIdentifier()); ?>"><?php p($backend->getText()); ?></option> |
141 | 150 | <?php endforeach; ?> |
142 | 151 | </select> |
@@ -164,7 +173,10 @@ discard block |
||
164 | 173 | |
165 | 174 | <?php if ($_['visibilityType'] === BackendService::VISIBILITY_ADMIN): ?> |
166 | 175 | <input type="checkbox" name="allowUserMounting" id="allowUserMounting" class="checkbox" |
167 | - value="1" <?php if ($_['allowUserMounting']) print_unescaped(' checked="checked"'); ?> /> |
|
176 | + value="1" <?php if ($_['allowUserMounting']) { |
|
177 | + print_unescaped(' checked="checked"'); |
|
178 | +} |
|
179 | +?> /> |
|
168 | 180 | <label for="allowUserMounting"><?php p($l->t('Allow users to mount external storage')); ?></label> <span id="userMountingMsg" class="msg"></span> |
169 | 181 | |
170 | 182 | <p id="userMountingBackends"<?php if (!$_['allowUserMounting']): ?> class="hidden"<?php endif; ?>> |
@@ -177,8 +189,14 @@ discard block |
||
177 | 189 | <?php $i = 0; foreach ($userBackends as $backend): ?> |
178 | 190 | <?php if ($deprecateTo = $backend->getDeprecateTo()): ?> |
179 | 191 | <input type="hidden" id="allowUserMountingBackends<?php p($i); ?>" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" data-deprecate-to="<?php p($deprecateTo->getIdentifier()); ?>" /> |
180 | - <?php else: ?> |
|
181 | - <input type="checkbox" id="allowUserMountingBackends<?php p($i); ?>" class="checkbox" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" <?php if ($backend->isVisibleFor(BackendService::VISIBILITY_PERSONAL)) print_unescaped(' checked="checked"'); ?> /> |
|
192 | + <?php else { |
|
193 | + : ?> |
|
194 | + <input type="checkbox" id="allowUserMountingBackends<?php p($i); |
|
195 | +} |
|
196 | +?>" class="checkbox" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" <?php if ($backend->isVisibleFor(BackendService::VISIBILITY_PERSONAL)) { |
|
197 | + print_unescaped(' checked="checked"'); |
|
198 | +} |
|
199 | +?> /> |
|
182 | 200 | <label for="allowUserMountingBackends<?php p($i); ?>"><?php p($backend->getText()); ?></label> <br /> |
183 | 201 | <?php endif; ?> |
184 | 202 | <?php $i++; ?> |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | $this->path=$source; |
47 | 47 | $this->zip=new \ZipArchive(); |
48 | 48 | if($this->zip->open($source, \ZipArchive::CREATE)) { |
49 | - }else{ |
|
49 | + } else{ |
|
50 | 50 | \OCP\Util::writeLog('files_archive', 'Error while opening archive '.$source, \OCP\Util::WARN); |
51 | 51 | } |
52 | 52 | } |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | public function addFile($path, $source='') { |
68 | 68 | if($source and $source[0]=='/' and file_exists($source)) { |
69 | 69 | $result=$this->zip->addFile($source, $path); |
70 | - }else{ |
|
70 | + } else{ |
|
71 | 71 | $result=$this->zip->addFromString($path, $source); |
72 | 72 | } |
73 | 73 | if($result) { |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | public function remove($path) { |
177 | 177 | if($this->fileExists($path.'/')) { |
178 | 178 | return $this->zip->deleteName($path.'/'); |
179 | - }else{ |
|
179 | + } else{ |
|
180 | 180 | return $this->zip->deleteName($path); |
181 | 181 | } |
182 | 182 | } |
@@ -195,7 +195,7 @@ discard block |
||
195 | 195 | //in the archive when the stream is closed |
196 | 196 | if(strrpos($path, '.')!==false) { |
197 | 197 | $ext=substr($path, strrpos($path, '.')); |
198 | - }else{ |
|
198 | + } else{ |
|
199 | 199 | $ext=''; |
200 | 200 | } |
201 | 201 | $tmpFile = \OC::$server->getTempManager()->getTemporaryFile($ext); |
@@ -224,7 +224,7 @@ discard block |
||
224 | 224 | private function stripPath($path) { |
225 | 225 | if(!$path || $path[0]=='/') { |
226 | 226 | return substr($path, 1); |
227 | - }else{ |
|
227 | + } else{ |
|
228 | 228 | return $path; |
229 | 229 | } |
230 | 230 | } |
@@ -35,7 +35,7 @@ |
||
35 | 35 | |
36 | 36 | if(OCA\Files_Versions\Storage::rollback( $file, $revision )) { |
37 | 37 | \OC_JSON::success(array("data" => array( "revision" => $revision, "file" => $file ))); |
38 | -}else{ |
|
38 | +} else{ |
|
39 | 39 | $l = \OC::$server->getL10N('files_versions'); |
40 | 40 | \OC_JSON::error(array("data" => array( "message" => $l->t("Could not revert: %s", array($file) )))); |
41 | 41 | } |