@@ -816,7 +816,7 @@ |
||
816 | 816 | |
817 | 817 | $out = 'POST /smf/stats/collect_stats.php HTTP/1.1' . "\r\n"; |
818 | 818 | $out .= 'Host: www.simplemachines.org' . "\r\n"; |
819 | - $out .= 'user-agent: '. SMF_USER_AGENT . "\r\n"; |
|
819 | + $out .= 'user-agent: ' . SMF_USER_AGENT . "\r\n"; |
|
820 | 820 | $out .= 'content-type: application/x-www-form-urlencoded' . "\r\n"; |
821 | 821 | $out .= 'connection: Close' . "\r\n"; |
822 | 822 | $out .= 'content-length: ' . $length . "\r\n\r\n"; |
@@ -67,8 +67,7 @@ |
||
67 | 67 | $sound_letter = substr($sound_letter, strpos($sound_letter, 'data') + 8); |
68 | 68 | switch ($word[$i] === 's' ? 0 : mt_rand(0, 2)) |
69 | 69 | { |
70 | - case 0 : |
|
71 | - for ($j = 0, $n = strlen($sound_letter); $j < $n; $j++) |
|
70 | + case 0 : for ($j = 0, $n = strlen($sound_letter); $j < $n; $j++) |
|
72 | 71 | for ($k = 0, $m = round(mt_rand(15, 25) / 10); $k < $m; $k++) |
73 | 72 | $sound_word .= $word[$i] === 's' ? $sound_letter[$j] : chr(mt_rand(max(ord($sound_letter[$j]) - 1, 0x00), min(ord($sound_letter[$j]) + 1, 0xFF))); |
74 | 73 | break; |
@@ -959,7 +959,7 @@ |
||
959 | 959 | $incontext['continue'] = 1; |
960 | 960 | |
961 | 961 | // Check Postgres setting |
962 | - if ( $db_type === 'postgresql') |
|
962 | + if ($db_type === 'postgresql') |
|
963 | 963 | { |
964 | 964 | load_database(); |
965 | 965 | $result = $smcFunc['db_query']('', ' |
@@ -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... |
@@ -1622,7 +1622,7 @@ discard block |
||
1622 | 1622 | // Determine action based on last_login... |
1623 | 1623 | $purgeMembers = array(); |
1624 | 1624 | $markReadMembers = array(); |
1625 | - foreach($members as $member) |
|
1625 | + foreach ($members as $member) |
|
1626 | 1626 | { |
1627 | 1627 | if ($member['last_login'] <= $cleanupBeyond) |
1628 | 1628 | $purgeMembers[] = $member['id_member']; |
@@ -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 |
@@ -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 |
@@ -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 |
@@ -317,7 +317,7 @@ |
||
317 | 317 | { |
318 | 318 | // PHPBB 3 check this function exists in PHP 5.5 or higher |
319 | 319 | if (function_exists('password_verify')) |
320 | - $other_passwords[] = password_verify($_POST['passwrd'],$user_settings['password_salt']); |
|
320 | + $other_passwords[] = password_verify($_POST['passwrd'], $user_settings['password_salt']); |
|
321 | 321 | |
322 | 322 | // PHP-Fusion |
323 | 323 | $other_passwords[] = hash_hmac('sha256', $_POST['passwrd'], $user_settings['password_salt']); |