@@ -1638,7 +1638,7 @@ |
||
1638 | 1638 | $cacheAPIdir = $sourcedir . '/Cache'; |
1639 | 1639 | |
1640 | 1640 | $loadedApis = array(); |
1641 | - $apis_dir = $cacheAPIdir .'/'. CacheApi::APIS_FOLDER; |
|
1641 | + $apis_dir = $cacheAPIdir . '/' . CacheApi::APIS_FOLDER; |
|
1642 | 1642 | |
1643 | 1643 | $api_classes = new GlobIterator($apis_dir . '/*.php', FilesystemIterator::NEW_CURRENT_AND_KEY); |
1644 | 1644 |
@@ -707,7 +707,6 @@ |
||
707 | 707 | $cache_level = array($txt['cache_off']); |
708 | 708 | $apis_names['none'] = $txt['cache_off']; |
709 | 709 | } |
710 | - |
|
711 | 710 | else |
712 | 711 | { |
713 | 712 | $txt['cache_settings_message'] = '<strong class="success">' . |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | $class_name = $this->getImplementationClassKeyName(); |
185 | 185 | $class_name_txt_key = strtolower($class_name); |
186 | 186 | |
187 | - $config_vars[] = $txt['cache_'. $class_name_txt_key .'_settings']; |
|
187 | + $config_vars[] = $txt['cache_' . $class_name_txt_key . '_settings']; |
|
188 | 188 | $config_vars[] = array('cachedir', $txt['cachedir'], 'file', 'text', 36, 'cache_cachedir'); |
189 | 189 | |
190 | 190 | if (!isset($context['settings_post_javascript'])) |
@@ -193,7 +193,7 @@ discard block |
||
193 | 193 | $context['settings_post_javascript'] .= ' |
194 | 194 | $("#cache_accelerator").change(function (e) { |
195 | 195 | var cache_type = e.currentTarget.value; |
196 | - $("#cachedir").prop("disabled", cache_type != "'. $class_name .'"); |
|
196 | + $("#cachedir").prop("disabled", cache_type != "'. $class_name . '"); |
|
197 | 197 | });'; |
198 | 198 | } |
199 | 199 |
@@ -131,14 +131,14 @@ discard block |
||
131 | 131 | $class_name = $this->getImplementationClassKeyName(); |
132 | 132 | $class_name_txt_key = strtolower($class_name); |
133 | 133 | |
134 | - $config_vars[] = $txt['cache_'. $class_name_txt_key .'_settings']; |
|
134 | + $config_vars[] = $txt['cache_' . $class_name_txt_key . '_settings']; |
|
135 | 135 | $config_vars[] = array( |
136 | - 'cachedir_'. $class_name_txt_key, |
|
137 | - $txt['cachedir_'. $class_name_txt_key], |
|
136 | + 'cachedir_' . $class_name_txt_key, |
|
137 | + $txt['cachedir_' . $class_name_txt_key], |
|
138 | 138 | 'file', |
139 | 139 | 'text', |
140 | 140 | 36, |
141 | - 'cache_'. $class_name_txt_key .'_cachedir'); |
|
141 | + 'cache_' . $class_name_txt_key . '_cachedir'); |
|
142 | 142 | |
143 | 143 | if (!isset($context['settings_post_javascript'])) |
144 | 144 | $context['settings_post_javascript'] = ''; |
@@ -146,7 +146,7 @@ discard block |
||
146 | 146 | $context['settings_post_javascript'] .= ' |
147 | 147 | $("#cache_accelerator").change(function (e) { |
148 | 148 | var cache_type = e.currentTarget.value; |
149 | - $("#cachedir_'. $class_name_txt_key .'").prop("disabled", cache_type != "'. $class_name .'"); |
|
149 | + $("#cachedir_'. $class_name_txt_key . '").prop("disabled", cache_type != "' . $class_name . '"); |
|
150 | 150 | });'; |
151 | 151 | } |
152 | 152 |
@@ -169,7 +169,7 @@ discard block |
||
169 | 169 | clean_cache(); |
170 | 170 | |
171 | 171 | // If warning decrement is enabled and we have people who have not had a new warning in 24 hours, lower their warning level. |
172 | - list (, , $modSettings['warning_decrement']) = explode(',', $modSettings['warning_settings']); |
|
172 | + list (,, $modSettings['warning_decrement']) = explode(',', $modSettings['warning_settings']); |
|
173 | 173 | if ($modSettings['warning_decrement']) |
174 | 174 | { |
175 | 175 | // Find every member who has a warning level... |
@@ -1665,7 +1665,7 @@ discard block |
||
1665 | 1665 | // Determine action based on last_login... |
1666 | 1666 | $purgeMembers = array(); |
1667 | 1667 | $markReadMembers = array(); |
1668 | - foreach($members as $member) |
|
1668 | + foreach ($members as $member) |
|
1669 | 1669 | { |
1670 | 1670 | if ($member['last_login'] <= $cleanupBeyond) |
1671 | 1671 | $purgeMembers[] = $member['id_member']; |
@@ -851,7 +851,7 @@ discard block |
||
851 | 851 | |
852 | 852 | clean_cache('data'); |
853 | 853 | |
854 | - cache_put_data('parsed_boards_descriptions_'. $parsed_boards_cat_id, $already_parsed_boards, 864000); |
|
854 | + cache_put_data('parsed_boards_descriptions_' . $parsed_boards_cat_id, $already_parsed_boards, 864000); |
|
855 | 855 | |
856 | 856 | if (empty($boardOptions['dont_log'])) |
857 | 857 | logAction('edit_board', array('board' => $board_id), 'admin'); |
@@ -1579,7 +1579,7 @@ discard block |
||
1579 | 1579 | $context['description_allowed_tags'] |
1580 | 1580 | ); |
1581 | 1581 | |
1582 | - cache_put_data('parsed_boards_descriptions_'. $category_id, $already_parsed_boards, 864000); |
|
1582 | + cache_put_data('parsed_boards_descriptions_' . $category_id, $already_parsed_boards, 864000); |
|
1583 | 1583 | |
1584 | 1584 | return $already_parsed_boards; |
1585 | 1585 | } |
@@ -195,8 +195,7 @@ |
||
195 | 195 | ); |
196 | 196 | |
197 | 197 | $categories[$row_board['id_cat']]['link'] = '<a id="c' . $row_board['id_cat'] . '"></a>' . (!$context['user']['is_guest'] ? |
198 | - '<a href="' . $scripturl . '?action=unread;c=' . $row_board['id_cat'] . '" title="' . sprintf($txt['new_posts_in_category'], $row_board['cat_name']) . '">' . $row_board['cat_name'] . '</a>' : |
|
199 | - $row_board['cat_name']); |
|
198 | + '<a href="' . $scripturl . '?action=unread;c=' . $row_board['id_cat'] . '" title="' . sprintf($txt['new_posts_in_category'], $row_board['cat_name']) . '">' . $row_board['cat_name'] . '</a>' : $row_board['cat_name']); |
|
200 | 199 | |
201 | 200 | } |
202 | 201 |
@@ -280,7 +280,6 @@ discard block |
||
280 | 280 | $this_category[$row_board['id_board']]['board_class'] = 'on'; |
281 | 281 | $this_category[$row_board['id_board']]['board_tooltip'] = $txt['new_posts']; |
282 | 282 | } |
283 | - |
|
284 | 283 | else |
285 | 284 | { |
286 | 285 | $this_category[$row_board['id_board']]['board_tooltip'] = $txt['old_posts']; |
@@ -415,7 +414,6 @@ discard block |
||
415 | 414 | $this_last_post['href'] = $scripturl . '?topic=' . $row_board['id_topic'] . '.msg' . ($user_info['is_guest'] ? $row_board['id_msg'] : $row_board['new_from']) . (empty($row_board['is_read']) ? ';boardseen' : '') . '#new'; |
416 | 415 | $this_last_post['link'] = '<a href="' . $this_last_post['href'] . '" title="' . $row_board['subject'] . '">' . $row_board['short_subject'] . '</a>'; |
417 | 416 | } |
418 | - |
|
419 | 417 | else |
420 | 418 | { |
421 | 419 | $this_last_post['href'] = ''; |
@@ -510,8 +508,7 @@ discard block |
||
510 | 508 | $board['last_post']['last_post_message'] = sprintf($txt['last_post_message'], $board['last_post']['member']['link'], $board['last_post']['link'], $board['last_post']['time'] > 0 ? timeformat($board['last_post']['time']) : $txt['not_applicable']); |
511 | 509 | } |
512 | 510 | } |
513 | - |
|
514 | - else |
|
511 | + else |
|
515 | 512 | foreach ($this_category as &$board) |
516 | 513 | { |
517 | 514 | if (isset($boards_parsed_data_by_cat_id[$board['id_cat']][$board['id']])) |
@@ -455,7 +455,7 @@ |
||
455 | 455 | |
456 | 456 | elseif ($context['uninstalling']) |
457 | 457 | echo ' |
458 | - ', $txt['package_uninstall_done'] .' <br> |
|
458 | + ', $txt['package_uninstall_done'] . ' <br> |
|
459 | 459 | ', '<a href="', $context['keep_url'], '" class="button">', $txt['package_keep'], '</a>', '<a href="', $context['remove_url'], '" class="button">', $txt['package_delete2'], '</a>'; |
460 | 460 | |
461 | 461 | elseif ($context['install_finished']) |
@@ -393,18 +393,18 @@ discard block |
||
393 | 393 | $quickbuttons = array( |
394 | 394 | 'approve' => array( |
395 | 395 | 'label' => $txt['approve'], |
396 | - 'href' => $scripturl.'?action=moderate;area=postmod;sa='.$context['current_view'].';start='.$context['start'].';'.$context['session_var'].'='.$context['session_id'].';approve='.$item['id'], |
|
396 | + 'href' => $scripturl . '?action=moderate;area=postmod;sa=' . $context['current_view'] . ';start=' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'] . ';approve=' . $item['id'], |
|
397 | 397 | 'icon' => 'approve', |
398 | 398 | ), |
399 | 399 | 'delete' => array( |
400 | 400 | 'label' => $txt['remove'], |
401 | - 'href' => $scripturl.'?action=moderate;area=postmod;sa='.$context['current_view'].';start='.$context['start'].';'.$context['session_var'].'='.$context['session_id'].';delete='.$item['id'], |
|
401 | + 'href' => $scripturl . '?action=moderate;area=postmod;sa=' . $context['current_view'] . ';start=' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'] . ';delete=' . $item['id'], |
|
402 | 402 | 'icon' => 'remove_button', |
403 | 403 | 'show' => $item['can_delete'] |
404 | 404 | ), |
405 | 405 | 'quickmod' => array( |
406 | 406 | 'class' => 'inline_mod_check', |
407 | - 'content' => '<input type="checkbox" name="item[]" value="'.$item['id'].'" checked>', |
|
407 | + 'content' => '<input type="checkbox" name="item[]" value="' . $item['id'] . '" checked>', |
|
408 | 408 | 'show' => !empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1 |
409 | 409 | ), |
410 | 410 | ); |
@@ -469,7 +469,7 @@ discard block |
||
469 | 469 | $quickbuttons = array( |
470 | 470 | 'delete' => array( |
471 | 471 | 'label' => $txt['remove_message'], |
472 | - 'href' => $scripturl.'?action=moderate;area=userwatch;sa=post;delete='.$post['id'].';start='.$context['start'].';'.$context['session_var'].'='.$context['session_id'], |
|
472 | + 'href' => $scripturl . '?action=moderate;area=userwatch;sa=post;delete=' . $post['id'] . ';start=' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
473 | 473 | 'javascript' => 'data-confirm="' . $txt['mc_watched_users_delete_post'] . '"', |
474 | 474 | 'class' => 'you_sure', |
475 | 475 | 'icon' => 'remove_button', |
@@ -742,7 +742,7 @@ |
||
742 | 742 | 'icon' => 'move', |
743 | 743 | ), |
744 | 744 | 'quickmod' => array( |
745 | - 'class' => 'inline_mod_check', |
|
745 | + 'class' => 'inline_mod_check', |
|
746 | 746 | 'content' => '<input type="checkbox" name="mark[' . $id . ']" value="' . $id . '">', |
747 | 747 | 'show' => $context['showCheckboxes'] |
748 | 748 | ) |
@@ -262,7 +262,7 @@ discard block |
||
262 | 262 | AND a.is_read = 0' : '') . (!empty($alertIDs) ? ' |
263 | 263 | AND a.id_alert IN ({array_int:alertIDs})' : '') . ' |
264 | 264 | ORDER BY id_alert DESC' . (!empty($limit) ? ' |
265 | - LIMIT {int:limit}' : '') . (!empty($offset) ?' |
|
265 | + LIMIT {int:limit}' : '') . (!empty($offset) ? ' |
|
266 | 266 | OFFSET {int:offset}' : ''), |
267 | 267 | array( |
268 | 268 | 'id_member' => $memID, |
@@ -361,7 +361,7 @@ discard block |
||
361 | 361 | |
362 | 362 | // Substitute $scripturl into the link formats. (Done here to make life easier for hooked mods.) |
363 | 363 | $formats = array_map( |
364 | - function ($format) use ($scripturl) |
|
364 | + function($format) use ($scripturl) |
|
365 | 365 | { |
366 | 366 | $format['link'] = str_replace('{scripturl}', $scripturl, $format['link']); |
367 | 367 | $format['text'] = str_replace('{scripturl}', $scripturl, $format['text']); |
@@ -1176,20 +1176,20 @@ discard block |
||
1176 | 1176 | $context['posts'][$key]['quickbuttons'] = array( |
1177 | 1177 | 'reply' => array( |
1178 | 1178 | 'label' => $txt['reply'], |
1179 | - 'href' => $scripturl.'?action=post;topic='.$post['topic'].'.'.$post['start'], |
|
1179 | + 'href' => $scripturl . '?action=post;topic=' . $post['topic'] . '.' . $post['start'], |
|
1180 | 1180 | 'icon' => 'reply_button', |
1181 | 1181 | 'show' => $post['can_reply'] |
1182 | 1182 | ), |
1183 | 1183 | 'quote' => array( |
1184 | 1184 | 'label' => $txt['quote_action'], |
1185 | - 'href' => $scripturl.'?action=post;topic='.$post['topic'].'.'.$post['start'].';quote='.$post['id'], |
|
1185 | + 'href' => $scripturl . '?action=post;topic=' . $post['topic'] . '.' . $post['start'] . ';quote=' . $post['id'], |
|
1186 | 1186 | 'icon' => 'quote', |
1187 | 1187 | 'show' => $post['can_quote'] |
1188 | 1188 | ), |
1189 | 1189 | 'remove' => array( |
1190 | 1190 | 'label' => $txt['remove'], |
1191 | - 'href' => $scripturl.'?action=deletemsg;msg='.$post['id'].';topic='.$post['topic'].';profile;u='.$context['member']['id'].';start='.$context['start'].';'.$context['session_var'].'='.$context['session_id'], |
|
1192 | - 'javascript' => 'data-confirm="'.$txt['remove_message'].'"', |
|
1191 | + 'href' => $scripturl . '?action=deletemsg;msg=' . $post['id'] . ';topic=' . $post['topic'] . ';profile;u=' . $context['member']['id'] . ';start=' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
1192 | + 'javascript' => 'data-confirm="' . $txt['remove_message'] . '"', |
|
1193 | 1193 | 'class' => 'you_sure', |
1194 | 1194 | 'icon' => 'remove_button', |
1195 | 1195 | 'show' => $post['can_delete'] |