@@ -501,7 +501,7 @@ discard block |
||
501 | 501 | ); |
502 | 502 | |
503 | 503 | $insert = array(); |
504 | - foreach ( $changed_boards[$board_action] as $board_id) |
|
504 | + foreach ($changed_boards[$board_action] as $board_id) |
|
505 | 505 | $insert[] = array($id_group, $board_id, $board_action == 'allow' ? 0 : 1); |
506 | 506 | |
507 | 507 | $smcFunc['db_insert']('insert', |
@@ -851,7 +851,7 @@ discard block |
||
851 | 851 | ); |
852 | 852 | |
853 | 853 | $insert = array(); |
854 | - foreach ( $changed_boards[$board_action] as $board_id) |
|
854 | + foreach ($changed_boards[$board_action] as $board_id) |
|
855 | 855 | $insert[] = array((int) $_REQUEST['group'], $board_id, $board_action == 'allow' ? 0 : 1); |
856 | 856 | |
857 | 857 | $smcFunc['db_insert']('insert', |
@@ -388,7 +388,7 @@ discard block |
||
388 | 388 | <script> |
389 | 389 | function swapPostGroup(isChecked) |
390 | 390 | { |
391 | - var is_moderator_group = ', (int)$context['is_moderator_group'], '; |
|
391 | + var is_moderator_group = ', (int) $context['is_moderator_group'], '; |
|
392 | 392 | var group_type = ', $context['group']['type'], '; |
393 | 393 | var min_posts_text = document.getElementById(\'min_posts_text\'); |
394 | 394 | var group_desc_text = document.getElementById(\'group_desc_text\'); |
@@ -453,7 +453,7 @@ discard block |
||
453 | 453 | if (empty($modSettings['deny_boards_access'])) |
454 | 454 | echo ' |
455 | 455 | <li class="category"> |
456 | - <a href="javascript:void(0);" onclick="selectBoards([', implode(', ', $category['child_ids']), '], \''.$form_id.'\'); return false;"><strong>', $category['name'], '</strong></a> |
|
456 | + <a href="javascript:void(0);" onclick="selectBoards([', implode(', ', $category['child_ids']), '], \'' . $form_id . '\'); return false;"><strong>', $category['name'], '</strong></a> |
|
457 | 457 | <ul>'; |
458 | 458 | else |
459 | 459 | echo ' |
@@ -1728,7 +1728,7 @@ |
||
1728 | 1728 | { |
1729 | 1729 | // Avoid double separators and empty titled sections |
1730 | 1730 | $empty_section = true; |
1731 | - for ($j=$i+1; $j <= count($context['theme_options']); $j++) |
|
1731 | + for ($j = $i + 1; $j <= count($context['theme_options']); $j++) |
|
1732 | 1732 | { |
1733 | 1733 | // Found another separator, so we're done |
1734 | 1734 | if (!is_array($context['theme_options'][$j])) |
@@ -143,7 +143,7 @@ |
||
143 | 143 | |
144 | 144 | // Redirect to the selector if they chose selective. |
145 | 145 | if ($_POST['step2'] == 'selective') |
146 | - redirectexit ('action=splittopics;sa=selectTopics;subname=' . $_POST['subname'] . ';topic=' . $topic . '.0;start2=0'); |
|
146 | + redirectexit('action=splittopics;sa=selectTopics;subname=' . $_POST['subname'] . ';topic=' . $topic . '.0;start2=0'); |
|
147 | 147 | |
148 | 148 | $_POST['at'] = (int) $_POST['at']; |
149 | 149 | $messagesToBeSplit = array(); |
@@ -563,7 +563,7 @@ discard block |
||
563 | 563 | $value['id'] = $key; |
564 | 564 | |
565 | 565 | $button = ' |
566 | - <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>'; |
|
566 | + <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>'; |
|
567 | 567 | |
568 | 568 | if (!empty($value['sub_buttons'])) |
569 | 569 | { |
@@ -613,7 +613,7 @@ discard block |
||
613 | 613 | global $txt; |
614 | 614 | |
615 | 615 | // Enable manipulation with hooks |
616 | - if(!empty($list_id)) |
|
616 | + if (!empty($list_id)) |
|
617 | 617 | call_integration_hook('integrate_' . $list_id . '_quickbuttons', array(&$list_items)); |
618 | 618 | |
619 | 619 | // Make sure the list has at least one shown item |
@@ -640,20 +640,20 @@ discard block |
||
640 | 640 | |
641 | 641 | // Print the quickbuttons |
642 | 642 | $output = ' |
643 | - <ul' . (!empty($list_id) ? ' id="quickbuttons_'.$list_id.'"' : '') . ' class="quickbuttons">'; |
|
643 | + <ul' . (!empty($list_id) ? ' id="quickbuttons_' . $list_id . '"' : '') . ' class="quickbuttons">'; |
|
644 | 644 | |
645 | 645 | // This is used for a list item or a sublist item |
646 | 646 | $list_item_format = function($li) |
647 | 647 | { |
648 | 648 | $html = ' |
649 | - <li' . (!empty($li['class']) ? ' class="'.$li['class'].'"' : '') . (!empty($li['id']) ? ' id="'.$li['id'].'"' : '') . (!empty($li['custom']) ? $li['custom'] : '') . '>'; |
|
649 | + <li' . (!empty($li['class']) ? ' class="' . $li['class'] . '"' : '') . (!empty($li['id']) ? ' id="' . $li['id'] . '"' : '') . (!empty($li['custom']) ? $li['custom'] : '') . '>'; |
|
650 | 650 | |
651 | - if(isset($li['content'])) |
|
651 | + if (isset($li['content'])) |
|
652 | 652 | $html .= $li['content']; |
653 | 653 | else |
654 | 654 | $html .= ' |
655 | - <a' . (!empty($li['href']) ? ' href="'.$li['href'].'"' : '') . (!empty($li['javascript']) ? $li['javascript'] : '') . '> |
|
656 | - ' . (!empty($li['icon']) ? '<span class="main_icons '.$li['icon'].'"></span>' : '') . (!empty($li['label']) ? $li['label'] : '') . ' |
|
655 | + <a' . (!empty($li['href']) ? ' href="' . $li['href'] . '"' : '') . (!empty($li['javascript']) ? $li['javascript'] : '') . '> |
|
656 | + ' . (!empty($li['icon']) ? '<span class="main_icons ' . $li['icon'] . '"></span>' : '') . (!empty($li['label']) ? $li['label'] : '') . ' |
|
657 | 657 | </a>'; |
658 | 658 | |
659 | 659 | $html .= ' |
@@ -665,7 +665,7 @@ discard block |
||
665 | 665 | foreach ($list_items as $key => $li) |
666 | 666 | { |
667 | 667 | // Handle the sublist |
668 | - if($key == 'more') |
|
668 | + if ($key == 'more') |
|
669 | 669 | { |
670 | 670 | $output .= ' |
671 | 671 | <li class="post_options">' . $txt['post_options'] . ' |
@@ -687,7 +687,7 @@ discard block |
||
687 | 687 | </ul><!-- .quickbuttons -->'; |
688 | 688 | |
689 | 689 | // There are a few spots where the result needs to be returned |
690 | - if($output_method == 'echo') |
|
690 | + if ($output_method == 'echo') |
|
691 | 691 | echo $output; |
692 | 692 | else |
693 | 693 | return $output; |
@@ -185,14 +185,14 @@ discard block |
||
185 | 185 | $report_buttons = array( |
186 | 186 | 'ignore' => array( |
187 | 187 | 'text' => !$context['report']['ignore'] ? 'mc_reportedp_ignore' : 'mc_reportedp_unignore', |
188 | - 'url' => $scripturl.'?action=moderate;area=reportedposts;sa=handle;ignore='.(int) !$context['report']['ignore'].';rid='.$context['report']['id'].';'.$context['session_var'].'='.$context['session_id'].';'.$context['mod-report-ignore_token_var'].'='.$context['mod-report-ignore_token'], |
|
188 | + 'url' => $scripturl . '?action=moderate;area=reportedposts;sa=handle;ignore=' . (int) !$context['report']['ignore'] . ';rid=' . $context['report']['id'] . ';' . $context['session_var'] . '=' . $context['session_id'] . ';' . $context['mod-report-ignore_token_var'] . '=' . $context['mod-report-ignore_token'], |
|
189 | 189 | 'class' => !$context['report']['ignore'] ? ' you_sure' : '', |
190 | 190 | 'custom' => !$context['report']['ignore'] ? ' data-confirm="' . $txt['mc_reportedp_ignore_confirm'] . '"' : '', |
191 | 191 | 'icon' => 'ignore' |
192 | 192 | ), |
193 | 193 | 'close' => array( |
194 | 194 | 'text' => $context['report']['closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', |
195 | - 'url' => $scripturl.'?action=moderate;area=reportedposts;sa=handle;closed='.(int) !$context['report']['closed'].';rid='.$context['report']['id'].';'.$context['session_var'].'='.$context['session_id'].';'.$context['mod-report-closed_token_var'].'='.$context['mod-report-closed_token'], |
|
195 | + 'url' => $scripturl . '?action=moderate;area=reportedposts;sa=handle;closed=' . (int) !$context['report']['closed'] . ';rid=' . $context['report']['id'] . ';' . $context['session_var'] . '=' . $context['session_id'] . ';' . $context['mod-report-closed_token_var'] . '=' . $context['mod-report-closed_token'], |
|
196 | 196 | 'icon' => 'close' |
197 | 197 | ) |
198 | 198 | ); |
@@ -465,14 +465,14 @@ discard block |
||
465 | 465 | $report_buttons = array( |
466 | 466 | 'ignore' => array( |
467 | 467 | 'text' => !$context['report']['ignore'] ? 'mc_reportedp_ignore' : 'mc_reportedp_unignore', |
468 | - 'url' => $scripturl.'?action=moderate;area=reportedmembers;sa=handle;ignore='.(int)!$context['report']['ignore'].';rid='.$context['report']['id'].';'.$context['session_var'].'='.$context['session_id'].';'.$context['mod-report-ignore_token_var'].'='.$context['mod-report-ignore_token'], |
|
468 | + 'url' => $scripturl . '?action=moderate;area=reportedmembers;sa=handle;ignore=' . (int) !$context['report']['ignore'] . ';rid=' . $context['report']['id'] . ';' . $context['session_var'] . '=' . $context['session_id'] . ';' . $context['mod-report-ignore_token_var'] . '=' . $context['mod-report-ignore_token'], |
|
469 | 469 | 'class' => !$context['report']['ignore'] ? ' you_sure' : '', |
470 | 470 | 'custom' => !$context['report']['ignore'] ? ' data-confirm="' . $txt['mc_reportedp_ignore_confirm'] . '"' : '', |
471 | 471 | 'icon' => 'ignore' |
472 | 472 | ), |
473 | 473 | 'close' => array( |
474 | 474 | 'text' => $context['report']['closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', |
475 | - 'url' => $scripturl.'?action=moderate;area=reportedmembers;sa=handle;closed='.(int)!$context['report']['closed'].';rid='.$context['report']['id'].';'.$context['session_var'].'='.$context['session_id'].';'.$context['mod-report-closed_token_var'].'='.$context['mod-report-closed_token'], |
|
475 | + 'url' => $scripturl . '?action=moderate;area=reportedmembers;sa=handle;closed=' . (int) !$context['report']['closed'] . ';rid=' . $context['report']['id'] . ';' . $context['session_var'] . '=' . $context['session_id'] . ';' . $context['mod-report-closed_token_var'] . '=' . $context['mod-report-closed_token'], |
|
476 | 476 | 'icon' => 'close' |
477 | 477 | ) |
478 | 478 | ); |
@@ -918,19 +918,19 @@ discard block |
||
918 | 918 | $quickbuttons = array( |
919 | 919 | 'quote' => array( |
920 | 920 | 'label' => $txt['reply_quote'], |
921 | - 'href' => $scripturl.'?action=pm;sa=send;f='.$context['folder'].($context['current_label_id'] != -1 ? ';l=' . $context['current_label_id'] : '').';pmsg='.$message['id'].';quote;u='.($context['folder'] == 'sent' ? '' : $message['member']['id']), |
|
921 | + 'href' => $scripturl . '?action=pm;sa=send;f=' . $context['folder'] . ($context['current_label_id'] != -1 ? ';l=' . $context['current_label_id'] : '') . ';pmsg=' . $message['id'] . ';quote;u=' . ($context['folder'] == 'sent' ? '' : $message['member']['id']), |
|
922 | 922 | 'icon' => 'quote', |
923 | 923 | 'show' => !$message['member']['is_guest'] |
924 | 924 | ), |
925 | 925 | 'reply' => array( |
926 | 926 | 'label' => $txt['reply'], |
927 | - 'href' => $scripturl.'?action=pm;sa=send;f='.$context['folder'].($context['current_label_id'] != -1 ? ';l=' . $context['current_label_id'] : '').';pmsg='.$message['id'].';u='.$message['member']['id'], |
|
927 | + 'href' => $scripturl . '?action=pm;sa=send;f=' . $context['folder'] . ($context['current_label_id'] != -1 ? ';l=' . $context['current_label_id'] : '') . ';pmsg=' . $message['id'] . ';u=' . $message['member']['id'], |
|
928 | 928 | 'icon' => 'reply_button', |
929 | 929 | 'show' => !$message['member']['is_guest'] |
930 | 930 | ), |
931 | 931 | 'reply_quote' => array( |
932 | 932 | 'label' => $txt['reply_quote'], |
933 | - 'href' => $scripturl.'?action=pm;sa=send;f='.$context['folder'].($context['current_label_id'] != -1 ? ';l=' . $context['current_label_id'] : '').';pmsg='.$message['id'].';quote', |
|
933 | + 'href' => $scripturl . '?action=pm;sa=send;f=' . $context['folder'] . ($context['current_label_id'] != -1 ? ';l=' . $context['current_label_id'] : '') . ';pmsg=' . $message['id'] . ';quote', |
|
934 | 934 | 'icon' => 'quote', |
935 | 935 | 'show' => $message['member']['is_guest'] |
936 | 936 | ) |
@@ -1956,7 +1956,7 @@ discard block |
||
1956 | 1956 | <div class="floatright smalltext righttext"> |
1957 | 1957 | <div class="recipient_to">« <strong>', $txt['to'], ':</strong> ', implode(', ', $draft['recipients']['to']), ' »</div>'; |
1958 | 1958 | |
1959 | - if(!empty($draft['recipients']['bcc'])) |
|
1959 | + if (!empty($draft['recipients']['bcc'])) |
|
1960 | 1960 | echo' |
1961 | 1961 | <div class="pm_bbc">« <strong>', $txt['pm_bcc'], ':</strong> ', implode(', ', $draft['recipients']['bcc']), ' »</div>'; |
1962 | 1962 |
@@ -393,17 +393,17 @@ 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 | - 'content' => '<input type="checkbox" name="item[]" value="'.$item['id'].'" checked>', |
|
406 | + 'content' => '<input type="checkbox" name="item[]" value="' . $item['id'] . '" checked>', |
|
407 | 407 | 'show' => !empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1 |
408 | 408 | ), |
409 | 409 | ); |
@@ -468,7 +468,7 @@ discard block |
||
468 | 468 | $quickbuttons = array( |
469 | 469 | 'delete' => array( |
470 | 470 | 'label' => $txt['remove_message'], |
471 | - 'href' => $scripturl.'?action=moderate;area=userwatch;sa=post;delete='.$post['id'].';start='.$context['start'].';'.$context['session_var'].'='.$context['session_id'], |
|
471 | + 'href' => $scripturl . '?action=moderate;area=userwatch;sa=post;delete=' . $post['id'] . ';start=' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
472 | 472 | 'javascript' => 'data-confirm="' . $txt['mc_watched_users_delete_post'] . '" class="you_sure"', |
473 | 473 | 'icon' => 'remove_button', |
474 | 474 | 'show' => $post['can_delete'] |
@@ -645,13 +645,13 @@ discard block |
||
645 | 645 | 'quickbuttons' => array( |
646 | 646 | 'edit' => array( |
647 | 647 | 'label' => $txt['draft_edit'], |
648 | - 'href' => $scripturl.'?action=post;'.(empty($row['id_topic']) ? 'board='.$row['id_board'] : 'topic='.$row['id_topic']).'.0;id_draft='.$row['id_draft'], |
|
648 | + 'href' => $scripturl . '?action=post;' . (empty($row['id_topic']) ? 'board=' . $row['id_board'] : 'topic=' . $row['id_topic']) . '.0;id_draft=' . $row['id_draft'], |
|
649 | 649 | 'icon' => 'modify_button' |
650 | 650 | ), |
651 | 651 | 'delete' => array( |
652 | 652 | 'label' => $txt['draft_delete'], |
653 | - 'href' => $scripturl.'?action=profile;u='.$context['member']['id'].';area=showdrafts;delete='.$row['id_draft'].';'.$context['session_var'].'='.$context['session_id'], |
|
654 | - 'javascript' => 'data-confirm="'.$txt['draft_remove'].'" class="you_sure"', |
|
653 | + 'href' => $scripturl . '?action=profile;u=' . $context['member']['id'] . ';area=showdrafts;delete=' . $row['id_draft'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
654 | + 'javascript' => 'data-confirm="' . $txt['draft_remove'] . '" class="you_sure"', |
|
655 | 655 | 'icon' => 'remove_button' |
656 | 656 | ), |
657 | 657 | ), |
@@ -837,13 +837,13 @@ discard block |
||
837 | 837 | 'quickbuttons' => array( |
838 | 838 | 'edit' => array( |
839 | 839 | 'label' => $txt['draft_edit'], |
840 | - 'href' => $scripturl.'?action=pm;sa=showpmdrafts;id_draft='.$row['id_draft'].';'.$context['session_var'].'='.$context['session_id'], |
|
840 | + 'href' => $scripturl . '?action=pm;sa=showpmdrafts;id_draft=' . $row['id_draft'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
841 | 841 | 'icon' => 'modify_button' |
842 | 842 | ), |
843 | 843 | 'delete' => array( |
844 | 844 | 'label' => $txt['draft_delete'], |
845 | - 'href' => $scripturl.'?action=pm;sa=showpmdrafts;delete='.$row['id_draft'].';'.$context['session_var'].'='.$context['session_id'], |
|
846 | - 'javascript' => 'data-confirm="'.$txt['draft_remove'].'?" class="you_sure"', |
|
845 | + 'href' => $scripturl . '?action=pm;sa=showpmdrafts;delete=' . $row['id_draft'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
846 | + 'javascript' => 'data-confirm="' . $txt['draft_remove'] . '?" class="you_sure"', |
|
847 | 847 | 'icon' => 'remove_button' |
848 | 848 | ), |
849 | 849 | ), |