@@ -330,7 +330,7 @@ |
||
| 330 | 330 | WHERE t.id_board = {int:current_board} ' |
| 331 | 331 | . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : ' |
| 332 | 332 | AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . (!empty($message_index_topic_wheres) ? ' |
| 333 | - AND ' . implode("\n\t\t\t\tAND ", $message_index_topic_wheres) : ''). ' |
|
| 333 | + AND ' . implode("\n\t\t\t\tAND ", $message_index_topic_wheres) : '') . ' |
|
| 334 | 334 | ORDER BY is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' . $_REQUEST['sort'] . ($ascending ? '' : ' DESC') . ' |
| 335 | 335 | LIMIT {int:maxindex} |
| 336 | 336 | OFFSET {int:start} '; |
@@ -574,7 +574,7 @@ |
||
| 574 | 574 | $value['id'] = $key; |
| 575 | 575 | |
| 576 | 576 | $button = ' |
| 577 | - <a class="button button_strip_' . $key . (!empty($value['active']) ? ' active' : '') . (isset($value['class']) ? ' ' . $value['class'] : '') . '" ' . (!empty($value['url']) ? 'href="' . $value['url'] . '"' : '') . ' ' . (isset($value['custom']) ? ' ' . $value['custom'] : '') . '>'.(!empty($value['icon']) ? '<span class="main_icons '.$value['icon'].'"></span>' : '').'' . $txt[$value['text']] . '</a>'; |
|
| 577 | + <a class="button button_strip_' . $key . (!empty($value['active']) ? ' active' : '') . (isset($value['class']) ? ' ' . $value['class'] : '') . '" ' . (!empty($value['url']) ? 'href="' . $value['url'] . '"' : '') . ' ' . (isset($value['custom']) ? ' ' . $value['custom'] : '') . '>' . (!empty($value['icon']) ? '<span class="main_icons ' . $value['icon'] . '"></span>' : '') . '' . $txt[$value['text']] . '</a>'; |
|
| 578 | 578 | |
| 579 | 579 | if (!empty($value['sub_buttons'])) |
| 580 | 580 | { |
@@ -1931,7 +1931,7 @@ |
||
| 1931 | 1931 | <div class="floatright smalltext righttext"> |
| 1932 | 1932 | <div class="recipient_to">« <strong>', $txt['to'], ':</strong> ', implode(', ', $draft['recipients']['to']), ' »</div>'; |
| 1933 | 1933 | |
| 1934 | - if(!empty($draft['recipients']['bcc'])) |
|
| 1934 | + if (!empty($draft['recipients']['bcc'])) |
|
| 1935 | 1935 | echo' |
| 1936 | 1936 | <div class="pm_bbc">« <strong>', $txt['pm_bcc'], ':</strong> ', implode(', ', $draft['recipients']['bcc']), ' »</div>'; |
| 1937 | 1937 | |
@@ -1241,7 +1241,7 @@ |
||
| 1241 | 1241 | // File Upload. |
| 1242 | 1242 | if ($context['can_post_attachment']) |
| 1243 | 1243 | { |
| 1244 | - $acceptedFiles = empty($context['allowed_extensions']) ? '' : implode(',', array_map(function ($val) use ($smcFunc) |
|
| 1244 | + $acceptedFiles = empty($context['allowed_extensions']) ? '' : implode(',', array_map(function($val) use ($smcFunc) |
|
| 1245 | 1245 | { |
| 1246 | 1246 | return !empty($val) ? ('.' . $smcFunc['htmltrim']($val)) : ''; |
| 1247 | 1247 | }, explode(',', $context['allowed_extensions']))); |
@@ -500,7 +500,7 @@ discard block |
||
| 500 | 500 | log_error(sprintf($txt['smiley_set_dir_not_found'], $set_names[array_search($set, $context['smiley_sets'])])); |
| 501 | 501 | |
| 502 | 502 | $context['smiley_sets'] = array_filter($context['smiley_sets'], function($v) use ($set) |
| 503 | - { |
|
| 503 | + { |
|
| 504 | 504 | return $v != $set; |
| 505 | 505 | }); |
| 506 | 506 | } |
@@ -3467,7 +3467,6 @@ discard block |
||
| 3467 | 3467 | } |
| 3468 | 3468 | } |
| 3469 | 3469 | } |
| 3470 | - |
|
| 3471 | 3470 | elseif (($value == 'upload' && allowedTo('profile_upload_avatar')) || $downloadedExternalAvatar) |
| 3472 | 3471 | { |
| 3473 | 3472 | if ((isset($_FILES['attachment']['name']) && $_FILES['attachment']['name'] != '') || $downloadedExternalAvatar) |
@@ -282,7 +282,7 @@ |
||
| 282 | 282 | '{db_prefix}log_notify', |
| 283 | 283 | array('id_member' => 'int', 'id_topic' => 'int', 'id_board' => 'int'), |
| 284 | 284 | array($user_info['id'], $log['id_topic'], 0), |
| 285 | - array('id_member','id_topic', 'id_board') |
|
| 285 | + array('id_member', 'id_topic', 'id_board') |
|
| 286 | 286 | ); |
| 287 | 287 | } |
| 288 | 288 | else |
@@ -127,7 +127,6 @@ |
||
| 127 | 127 | |
| 128 | 128 | return false; |
| 129 | 129 | } |
| 130 | - |
|
| 131 | 130 | else |
| 132 | 131 | return true; |
| 133 | 132 | } |
@@ -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 | |
@@ -310,7 +310,7 @@ |
||
| 310 | 310 | { |
| 311 | 311 | /** |
| 312 | 312 | * Constants for notification types. |
| 313 | - */ |
|
| 313 | + */ |
|
| 314 | 314 | const RECEIVE_NOTIFY_EMAIL = 0x02; |
| 315 | 315 | const RECEIVE_NOTIFY_ALERT = 0x01; |
| 316 | 316 | |
@@ -93,7 +93,6 @@ |
||
| 93 | 93 | if ($ts <= 0 || $ts % 15 != 0 || time() - $ts < 0 || time() - $ts > 20) |
| 94 | 94 | obExit_cron(); |
| 95 | 95 | } |
| 96 | - |
|
| 97 | 96 | else |
| 98 | 97 | $_SERVER['SERVER_PROTOCOL'] = 'HTTP/1.0'; |
| 99 | 98 | |
@@ -19,7 +19,7 @@ discard block |
||
| 19 | 19 | { |
| 20 | 20 | /** |
| 21 | 21 | * Constants for reply types. |
| 22 | - */ |
|
| 22 | + */ |
|
| 23 | 23 | const NOTIFY_TYPE_REPLY_AND_MODIFY = 1; |
| 24 | 24 | const NOTIFY_TYPE_REPLY_AND_TOPIC_START_FOLLOWING = 2; |
| 25 | 25 | const NOTIFY_TYPE_ONLY_REPLIES = 3; |
@@ -27,7 +27,7 @@ discard block |
||
| 27 | 27 | |
| 28 | 28 | /** |
| 29 | 29 | * Constants for frequencies. |
| 30 | - */ |
|
| 30 | + */ |
|
| 31 | 31 | const FREQUENCY_NOTHING = 0; |
| 32 | 32 | const FREQUENCY_EVERYTHING = 1; |
| 33 | 33 | const FREQUENCY_FIRST_UNREAD_MSG = 2; |
@@ -266,7 +266,6 @@ |
||
| 266 | 266 | $user_info = $real_user_info; |
| 267 | 267 | unset($real_user_info); |
| 268 | 268 | } |
| 269 | - |
|
| 270 | 269 | else |
| 271 | 270 | $user_info = null; |
| 272 | 271 | |
@@ -118,7 +118,7 @@ discard block |
||
| 118 | 118 | if ($type == 'edit') |
| 119 | 119 | { |
| 120 | 120 | // Filter out members who have already been notified about this post's topic |
| 121 | - $unnotified = array_filter($watched, function ($member) |
|
| 121 | + $unnotified = array_filter($watched, function($member) |
|
| 122 | 122 | { |
| 123 | 123 | return empty($member['sent']); |
| 124 | 124 | }); |
@@ -204,8 +204,7 @@ discard block |
||
| 204 | 204 | if (!empty($member_data['id_topic']) && $type != 'topic' && !empty($prefs[$member_id])) |
| 205 | 205 | { |
| 206 | 206 | $pref = !empty($prefs[$member_id]['topic_notify_' . $topicOptions['id']]) ? |
| 207 | - $prefs[$member_id]['topic_notify_' . $topicOptions['id']] : |
|
| 208 | - (!empty($prefs[$member_id]['topic_notify']) ? $prefs[$member_id]['topic_notify'] : 0); |
|
| 207 | + $prefs[$member_id]['topic_notify_' . $topicOptions['id']] : (!empty($prefs[$member_id]['topic_notify']) ? $prefs[$member_id]['topic_notify'] : 0); |
|
| 209 | 208 | |
| 210 | 209 | $message_type = 'notification_' . $type; |
| 211 | 210 | |
@@ -224,8 +223,7 @@ discard block |
||
| 224 | 223 | elseif ($type == 'topic') |
| 225 | 224 | { |
| 226 | 225 | $pref = !empty($prefs[$member_id]['board_notify_' . $topicOptions['board']]) ? |
| 227 | - $prefs[$member_id]['board_notify_' . $topicOptions['board']] : |
|
| 228 | - (!empty($prefs[$member_id]['board_notify']) ? $prefs[$member_id]['board_notify'] : 0); |
|
| 226 | + $prefs[$member_id]['board_notify_' . $topicOptions['board']] : (!empty($prefs[$member_id]['board_notify']) ? $prefs[$member_id]['board_notify'] : 0); |
|
| 229 | 227 | |
| 230 | 228 | $content_type = 'board'; |
| 231 | 229 | |