@@ -2,6 +2,9 @@ |
||
| 2 | 2 | |
| 3 | 3 | // Try to handle it with the upper level index.php. (it should know what to do.) |
| 4 | 4 | if (file_exists(dirname(dirname(__FILE__)) . '/index.php')) |
| 5 | +{ |
|
| 5 | 6 | include (dirname(dirname(__FILE__)) . '/index.php'); |
| 6 | -else |
|
| 7 | - exit; |
|
| 8 | 7 | \ No newline at end of file |
| 8 | +} |
|
| 9 | +else { |
|
| 10 | + exit; |
|
| 11 | +} |
|
@@ -44,7 +44,7 @@ |
||
| 44 | 44 | ORDER BY m.icon_order', |
| 45 | 45 | [] |
| 46 | 46 | )->fetch_callback( |
| 47 | - function ($row) use (&$icons, &$last_icon, &$trueOrder) { |
|
| 47 | + function($row) use (&$icons, &$last_icon, &$trueOrder) { |
|
| 48 | 48 | global $settings, $txt; |
| 49 | 49 | |
| 50 | 50 | $icons[$row['id_icon']] = [ |
@@ -108,7 +108,7 @@ discard block |
||
| 108 | 108 | 'moderate_forum' => 'moderate_forum', |
| 109 | 109 | ] |
| 110 | 110 | )->fetch_callback( |
| 111 | - function ($row) use (&$groups) { |
|
| 111 | + function($row) use (&$groups) { |
|
| 112 | 112 | $groups[] = $row['id_group']; |
| 113 | 113 | } |
| 114 | 114 | ); |
@@ -132,7 +132,7 @@ discard block |
||
| 132 | 132 | 'group_array_implode' => implode(', additional_groups) != 0 OR FIND_IN_SET(', $groups), |
| 133 | 133 | ] |
| 134 | 134 | )->fetch_callback( |
| 135 | - function ($row) use ($type, $member_name, $memberID, $language) { |
|
| 135 | + function($row) use ($type, $member_name, $memberID, $language) { |
|
| 136 | 136 | global $scripturl, $modSettings; |
| 137 | 137 | |
| 138 | 138 | $replacements = [ |
@@ -284,7 +284,7 @@ discard block |
||
| 284 | 284 | 'mention_types' => $notification_types, |
| 285 | 285 | ] |
| 286 | 286 | )->fetch_callback( |
| 287 | - function ($row) use (&$results) { |
|
| 287 | + function($row) use (&$results) { |
|
| 288 | 288 | if (!isset($results[$row['id_member']])) |
| 289 | 289 | { |
| 290 | 290 | $results[$row['id_member']] = []; |
@@ -502,7 +502,7 @@ discard block |
||
| 502 | 502 | return false; |
| 503 | 503 | } |
| 504 | 504 | |
| 505 | - $blowfish_salt = '$2a$07$' . $memSalt . $modSettings['unsubscribe_site_salt']. '$'; |
|
| 505 | + $blowfish_salt = '$2a$07$' . $memSalt . $modSettings['unsubscribe_site_salt'] . '$'; |
|
| 506 | 506 | $expected = substr($blowfish_salt, 0, 28) . $hash; |
| 507 | 507 | $check = crypt($area . $memEmail . $memSalt, $blowfish_salt); |
| 508 | 508 | |
@@ -540,7 +540,7 @@ discard block |
||
| 540 | 540 | 'attachment_type' => 0, |
| 541 | 541 | ] |
| 542 | 542 | )->fetch_callback( |
| 543 | - function ($row) use (&$topicData, &$boards_index, $type) { |
|
| 543 | + function($row) use (&$topicData, &$boards_index, $type) { |
|
| 544 | 544 | // all the boards for these topics, used to find all the members to be notified |
| 545 | 545 | $boards_index[] = $row['id_board']; |
| 546 | 546 | |
@@ -632,7 +632,7 @@ discard block |
||
| 632 | 632 | 'members_only' => is_array($members_only) ? $members_only : [$members_only], |
| 633 | 633 | ] |
| 634 | 634 | )->fetch_callback( |
| 635 | - function ($row) use (&$boardNotifyData) { |
|
| 635 | + function($row) use (&$boardNotifyData) { |
|
| 636 | 636 | // The board subscription information for the member |
| 637 | 637 | $clean = [ |
| 638 | 638 | 'id_member' => (int) $row['id_member'], |
@@ -715,7 +715,7 @@ discard block |
||
| 715 | 715 | 'members_only' => is_array($members_only) ? $members_only : [$members_only], |
| 716 | 716 | ] |
| 717 | 717 | )->fetch_callback( |
| 718 | - function ($row) use (&$topicNotifyData) { |
|
| 718 | + function($row) use (&$topicNotifyData) { |
|
| 719 | 719 | // The topic subscription information for the member |
| 720 | 720 | $clean = [ |
| 721 | 721 | 'id_member' => (int) $row['id_member'], |
@@ -819,7 +819,7 @@ discard block |
||
| 819 | 819 | 'notify_regularity' => 2, |
| 820 | 820 | ] |
| 821 | 821 | )->fetch_callback( |
| 822 | - function ($row) use (&$approvalNotifyData) { |
|
| 822 | + function($row) use (&$approvalNotifyData) { |
|
| 823 | 823 | $clean = [ |
| 824 | 824 | 'id_member' => (int) $row['id_member'], |
| 825 | 825 | 'email_address' => $row['email_address'], |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | 'smiley_list' => $smileys, |
| 44 | 44 | ] |
| 45 | 45 | )->fetch_callback( |
| 46 | - function ($row) use (&$found) { |
|
| 46 | + function($row) use (&$found) { |
|
| 47 | 47 | $found[] = $row['filename']; |
| 48 | 48 | } |
| 49 | 49 | ); |
@@ -212,7 +212,7 @@ discard block |
||
| 212 | 212 | 'current_smiley' => $id, |
| 213 | 213 | ] |
| 214 | 214 | )->fetch_callback( |
| 215 | - function ($row) use (&$current_smiley) |
|
| 215 | + function($row) use (&$current_smiley) |
|
| 216 | 216 | { |
| 217 | 217 | $current_smiley = [ |
| 218 | 218 | 'id' => $row['id'], |
@@ -380,7 +380,7 @@ discard block |
||
| 380 | 380 | 'hidden' => 1, |
| 381 | 381 | ] |
| 382 | 382 | )->fetch_callback( |
| 383 | - function ($row) use (&$smileys) { |
|
| 383 | + function($row) use (&$smileys) { |
|
| 384 | 384 | global $context; |
| 385 | 385 | |
| 386 | 386 | $location = empty($row['hidden']) ? 'postform' : 'popup'; |
@@ -629,7 +629,7 @@ discard block |
||
| 629 | 629 | { |
| 630 | 630 | global $modSettings; |
| 631 | 631 | |
| 632 | - $smiley_types = ['jpg', 'gif', 'jpeg', 'png', 'webp', 'svg']; |
|
| 632 | + $smiley_types = ['jpg', 'gif', 'jpeg', 'png', 'webp', 'svg']; |
|
| 633 | 633 | $smileys_dir = empty($modSettings['smileys_dir']) ? BOARDDIR . '/smileys' : $modSettings['smileys_dir']; |
| 634 | 634 | $fileFunc = FileFunctions::instance(); |
| 635 | 635 | $extensionTypes = []; |
@@ -687,7 +687,7 @@ discard block |
||
| 687 | 687 | ORDER BY smiley_row, smiley_order', |
| 688 | 688 | [] |
| 689 | 689 | )->fetch_callback( |
| 690 | - function ($row) use (&$smileys, $context) { |
|
| 690 | + function($row) use (&$smileys, $context) { |
|
| 691 | 691 | $filename = $row['filename'] . '.' . $context['smiley_extension']; |
| 692 | 692 | if (possibleSmileEmoji($row)) |
| 693 | 693 | { |
@@ -738,7 +738,7 @@ discard block |
||
| 738 | 738 | if ($test !== $row['filename'] && preg_match('~data-emoji-code=["\'](.*?)["\']~', $test, $result)) |
| 739 | 739 | { |
| 740 | 740 | // Valid emoji, set the filename to the proper emoji file and type |
| 741 | - $row['emoji'] = $result[1]; |
|
| 741 | + $row['emoji'] = $result[1]; |
|
| 742 | 742 | return true; |
| 743 | 743 | } |
| 744 | 744 | } |
@@ -486,7 +486,7 @@ |
||
| 486 | 486 | { |
| 487 | 487 | // Now loop through the remaining (database-based) settings. |
| 488 | 488 | $this->configVars = array_map( |
| 489 | - static function ($configVar) { |
|
| 489 | + static function($configVar) { |
|
| 490 | 490 | // We just saved the file-based settings, so skip their definitions. |
| 491 | 491 | if (!is_array($configVar) || $configVar[2] === 'file') |
| 492 | 492 | { |
@@ -275,7 +275,7 @@ |
||
| 275 | 275 | { |
| 276 | 276 | global $modSettings; |
| 277 | 277 | |
| 278 | - set_error_handler(static function () { /* ignore errors */ }); |
|
| 278 | + set_error_handler(static function() { /* ignore errors */ }); |
|
| 279 | 279 | try |
| 280 | 280 | { |
| 281 | 281 | $mySphinx = mysqli_connect(($modSettings['sphinx_searchd_server'] === 'localhost' ? '127.0.0.1' : $modSettings['sphinx_searchd_server']), '', '', '', (int) $modSettings['sphinxql_searchd_port']); |
@@ -777,7 +777,7 @@ |
||
| 777 | 777 | updateTopicStats(); |
| 778 | 778 | require_once(SUBSDIR . '/Messages.subs.php'); |
| 779 | 779 | updateMessageStats(); |
| 780 | - updateSettings(['calendar_updated' => time(),]); |
|
| 780 | + updateSettings(['calendar_updated' => time(), ]); |
|
| 781 | 781 | |
| 782 | 782 | if (!empty($affectedBoards)) |
| 783 | 783 | { |
@@ -230,7 +230,7 @@ |
||
| 230 | 230 | </div>'; |
| 231 | 231 | } |
| 232 | 232 | |
| 233 | - $has_top_border =(!empty($message['member']['signature']) && empty($options['show_no_signatures']) && $context['signature_enabled']) |
|
| 233 | + $has_top_border = (!empty($message['member']['signature']) && empty($options['show_no_signatures']) && $context['signature_enabled']) |
|
| 234 | 234 | || (!empty($message['member']['custom_fields']) && empty($options['show_no_signatures']) && $context['signature_enabled']); |
| 235 | 235 | |
| 236 | 236 | echo ' |
@@ -607,8 +607,7 @@ |
||
| 607 | 607 | if ($subIdCheck === $subId |
| 608 | 608 | || (empty($this->currentSubaction) && $sub->isDefault()) |
| 609 | 609 | || in_array($subIdCheck, $sub->getActive(), true) |
| 610 | - ) |
|
| 611 | - { |
|
| 610 | + ) { |
|
| 612 | 611 | $this->currentSubaction = $subId; |
| 613 | 612 | } |
| 614 | 613 | } |