@@ -1661,14 +1661,14 @@ discard block |
||
1661 | 1661 | $output['quickbuttons'] = array( |
1662 | 1662 | 'quote' => array( |
1663 | 1663 | 'label' => $txt['quote_action'], |
1664 | - 'href' => $scripturl.'?action=post;quote='.$output['id'].';topic='.$context['current_topic'], '.'.$context['start'].';last_msg='.$context['topic_last_message'], |
|
1665 | - 'javascript' => 'onclick="return oQuickReply.quote('.$output['id'].');"', |
|
1664 | + 'href' => $scripturl . '?action=post;quote=' . $output['id'] . ';topic=' . $context['current_topic'], '.' . $context['start'] . ';last_msg=' . $context['topic_last_message'], |
|
1665 | + 'javascript' => 'onclick="return oQuickReply.quote(' . $output['id'] . ');"', |
|
1666 | 1666 | 'icon' => 'quote', |
1667 | 1667 | 'show' => $context['can_quote'] |
1668 | 1668 | ), |
1669 | 1669 | 'quote_selected' => array( |
1670 | 1670 | 'label' => $txt['quote_selected_action'], |
1671 | - 'id' => 'quoteSelected_'. $output['id'], |
|
1671 | + 'id' => 'quoteSelected_' . $output['id'], |
|
1672 | 1672 | 'href' => 'javascript:void(0)', |
1673 | 1673 | 'custom' => 'style="display:none"', |
1674 | 1674 | 'icon' => 'quote_selected', |
@@ -1677,71 +1677,71 @@ discard block |
||
1677 | 1677 | 'quick_edit' => array( |
1678 | 1678 | 'label' => $txt['quick_edit'], |
1679 | 1679 | 'class' => 'quick_edit', |
1680 | - 'id' =>' modify_button_'. $output['id'], |
|
1681 | - 'custom' => 'onclick="oQuickModify.modifyMsg(\''.$output['id'].'\', \''.!empty($modSettings['toggle_subject']).'\')"', |
|
1680 | + 'id' =>' modify_button_' . $output['id'], |
|
1681 | + 'custom' => 'onclick="oQuickModify.modifyMsg(\'' . $output['id'] . '\', \'' . !empty($modSettings['toggle_subject']) . '\')"', |
|
1682 | 1682 | 'icon' => 'quick_edit_button', |
1683 | 1683 | 'show' => $output['can_modify'] |
1684 | 1684 | ), |
1685 | 1685 | 'more' => array( |
1686 | 1686 | 'modify' => array( |
1687 | 1687 | 'label' => $txt['modify'], |
1688 | - 'href' => $scripturl.'?action=post;msg='.$output['id'].';topic='.$context['current_topic'].'.'.$context['start'], |
|
1688 | + 'href' => $scripturl . '?action=post;msg=' . $output['id'] . ';topic=' . $context['current_topic'] . '.' . $context['start'], |
|
1689 | 1689 | 'icon' => 'modify_button', |
1690 | 1690 | 'show' => $output['can_modify'] |
1691 | 1691 | ), |
1692 | 1692 | 'remove_topic' => array( |
1693 | 1693 | 'label' => $txt['remove_topic'], |
1694 | - 'href' => $scripturl.'?action=removetopic2;topic='.$context['current_topic'].'.'.$context['start'].';'.$context['session_var'].'='.$context['session_id'], |
|
1695 | - 'javascript' => 'data-confirm="'.$txt['are_sure_remove_topic'].'" class="you_sure"', |
|
1694 | + 'href' => $scripturl . '?action=removetopic2;topic=' . $context['current_topic'] . '.' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
1695 | + 'javascript' => 'data-confirm="' . $txt['are_sure_remove_topic'] . '" class="you_sure"', |
|
1696 | 1696 | 'icon' => 'remove_button', |
1697 | 1697 | 'show' => $context['can_delete'] && ($context['topic_first_message'] == $output['id']) |
1698 | 1698 | ), |
1699 | 1699 | 'remove' => array( |
1700 | 1700 | 'label' => $txt['remove'], |
1701 | - 'href' => $scripturl.'?action=deletemsg;topic='.$context['current_topic'].'.'.$context['start'].';msg='.$output['id'].';'.$context['session_var'].'='.$context['session_id'], |
|
1702 | - 'javascript' => 'data-confirm="'.$txt['remove_message_question'].'" class="you_sure"', |
|
1701 | + 'href' => $scripturl . '?action=deletemsg;topic=' . $context['current_topic'] . '.' . $context['start'] . ';msg=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
1702 | + 'javascript' => 'data-confirm="' . $txt['remove_message_question'] . '" class="you_sure"', |
|
1703 | 1703 | 'icon' => 'remove_button', |
1704 | 1704 | 'show' => $output['can_remove'] && ($context['topic_first_message'] != $output['id']) |
1705 | 1705 | ), |
1706 | 1706 | 'split' => array( |
1707 | 1707 | 'label' => $txt['split'], |
1708 | - 'href' => $scripturl.'?action=splittopics;topic='.$context['current_topic'].'.0;at='.$output['id'], |
|
1708 | + 'href' => $scripturl . '?action=splittopics;topic=' . $context['current_topic'] . '.0;at=' . $output['id'], |
|
1709 | 1709 | 'icon' => 'split_button', |
1710 | 1710 | 'show' => $context['can_split'] && !empty($context['real_num_replies']) |
1711 | 1711 | ), |
1712 | 1712 | 'report' => array( |
1713 | 1713 | 'label' => $txt['report_to_mod'], |
1714 | - 'href' => $scripturl.'?action=reporttm;topic='.$context['current_topic'].'.'.$output['counter'].';msg='.$output['id'], |
|
1714 | + 'href' => $scripturl . '?action=reporttm;topic=' . $context['current_topic'] . '.' . $output['counter'] . ';msg=' . $output['id'], |
|
1715 | 1715 | 'icon' => 'error', |
1716 | 1716 | 'show' => $context['can_report_moderator'] |
1717 | 1717 | ), |
1718 | 1718 | 'warn' => array( |
1719 | 1719 | 'label' => $txt['issue_warning'], |
1720 | - 'href' => $scripturl, '?action=profile;area=issuewarning;u='.$output['member']['id'].';msg='.$output['id'], |
|
1720 | + 'href' => $scripturl, '?action=profile;area=issuewarning;u=' . $output['member']['id'] . ';msg=' . $output['id'], |
|
1721 | 1721 | 'icon' => 'warn_button', |
1722 | 1722 | 'show' => $context['can_issue_warning'] && !$output['is_message_author'] && !$output['member']['is_guest'] |
1723 | 1723 | ), |
1724 | 1724 | 'restore' => array( |
1725 | 1725 | 'label' => $txt['restore_message'], |
1726 | - 'href' => $scripturl.'?action=restoretopic;msgs='.$output['id'].';'.$context['session_var'].'='.$context['session_id'], |
|
1726 | + 'href' => $scripturl . '?action=restoretopic;msgs=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
1727 | 1727 | 'icon' => 'restore_button', |
1728 | 1728 | 'show' => $context['can_restore_msg'] |
1729 | 1729 | ), |
1730 | 1730 | 'approve' => array( |
1731 | 1731 | 'label' => $txt['approve'], |
1732 | - 'href' => $scripturl.'?action=moderate;area=postmod;sa=approve;topic='.$context['current_topic'].'.'.$context['start'].';msg='.$output['id'].';'.$context['session_var'].'='.$context['session_id'], |
|
1732 | + 'href' => $scripturl . '?action=moderate;area=postmod;sa=approve;topic=' . $context['current_topic'] . '.' . $context['start'] . ';msg=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
1733 | 1733 | 'icon' => 'approve_button', |
1734 | 1734 | 'show' => $output['can_approve'] |
1735 | 1735 | ), |
1736 | 1736 | 'unapprove' => array( |
1737 | 1737 | 'label' => $txt['unapprove'], |
1738 | - 'href' => $scripturl.'?action=moderate;area=postmod;sa=approve;topic='.$context['current_topic'].'.'.$context['start'].';msg='.$output['id'].';'.$context['session_var'].'='.$context['session_id'], |
|
1738 | + 'href' => $scripturl . '?action=moderate;area=postmod;sa=approve;topic=' . $context['current_topic'] . '.' . $context['start'] . ';msg=' . $output['id'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
1739 | 1739 | 'icon' => 'unapprove_button', |
1740 | 1740 | 'show' => $output['can_unapprove'] |
1741 | 1741 | ), |
1742 | 1742 | ), |
1743 | 1743 | 'quickmod' => array( |
1744 | - 'id' => 'in_topic_mod_check_'. $output['id'], |
|
1744 | + 'id' => 'in_topic_mod_check_' . $output['id'], |
|
1745 | 1745 | 'custom' => 'style="display: none;"', |
1746 | 1746 | 'content' => '', |
1747 | 1747 | 'show' => !empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1 && $output['can_remove'], |
@@ -1282,7 +1282,7 @@ |
||
1282 | 1282 | // File Upload. |
1283 | 1283 | if ($context['can_post_attachment']) |
1284 | 1284 | { |
1285 | - $acceptedFiles = implode(',', array_map(function ($val) use ($smcFunc) |
|
1285 | + $acceptedFiles = implode(',', array_map(function($val) use ($smcFunc) |
|
1286 | 1286 | { |
1287 | 1287 | return '.' . $smcFunc['htmltrim']($val); |
1288 | 1288 | }, explode(',', $context['allowed_extensions']))); |
@@ -619,7 +619,7 @@ |
||
619 | 619 | if (!empty($modSettings['force_ssl']) && empty($maintenance) && !httpsOn()) |
620 | 620 | fatal_lang_error('login_ssl_required', false); |
621 | 621 | |
622 | - $password = isset($_POST['oldpasswrd']) ? $_POST['oldpasswrd'] : ''; |
|
622 | + $password = isset($_POST['oldpasswrd']) ? $_POST['oldpasswrd'] : ''; |
|
623 | 623 | |
624 | 624 | // You didn't even enter a password! |
625 | 625 | if (trim($password) == '') |
@@ -422,7 +422,7 @@ discard block |
||
422 | 422 | { |
423 | 423 | $extra = $alerts[$id_alert]['extra']; |
424 | 424 | $search = array('{member_link}', '{scripturl}'); |
425 | - $repl = array(!empty($alert['sender_id']) && $alert['show_links'] ? '<a href="' . $scripturl . '?action=profile;u=' . $alert['sender_id'] . '">' . $alert['sender_name'] . '</a>' : '<strong>'.$alert['sender_name'].'</strong>', $scripturl); |
|
425 | + $repl = array(!empty($alert['sender_id']) && $alert['show_links'] ? '<a href="' . $scripturl . '?action=profile;u=' . $alert['sender_id'] . '">' . $alert['sender_name'] . '</a>' : '<strong>' . $alert['sender_name'] . '</strong>', $scripturl); |
|
426 | 426 | |
427 | 427 | if (is_array($extra)) |
428 | 428 | { |
@@ -453,7 +453,7 @@ discard block |
||
453 | 453 | // Are we opening a specific alert ? |
454 | 454 | if (!empty($_REQUEST['alert'])) |
455 | 455 | { |
456 | - $alert_id = (int)$_REQUEST['alert']; |
|
456 | + $alert_id = (int) $_REQUEST['alert']; |
|
457 | 457 | $request = $smcFunc['db_query']('', ' |
458 | 458 | SELECT id_member, id_member_started, content_type, content_action, content_id, is_read, extra |
459 | 459 | FROM {db_prefix}user_alerts |
@@ -466,10 +466,10 @@ discard block |
||
466 | 466 | $smcFunc['db_free_result']($request); |
467 | 467 | |
468 | 468 | // Can the user see this alert ? |
469 | - if($memID != $alert['id_member']) |
|
469 | + if ($memID != $alert['id_member']) |
|
470 | 470 | redirectexit(); |
471 | 471 | |
472 | - if(!empty($alert['extra'])) |
|
472 | + if (!empty($alert['extra'])) |
|
473 | 473 | $alert['extra'] = $smcFunc['json_decode']($alert['extra'], true); |
474 | 474 | |
475 | 475 | // Determine where the alert takes |
@@ -540,17 +540,17 @@ discard block |
||
540 | 540 | $context['alerts'][$id]['quickbuttons'] = array( |
541 | 541 | 'delete' => array( |
542 | 542 | 'label' => $txt['delete'], |
543 | - 'href' => $scripturl.'?action=profile;u='.$context['id_member'].';area=showalerts;do=remove;aid='.$id.';'.$context['session_var'].'='.$context['session_id'], |
|
543 | + 'href' => $scripturl . '?action=profile;u=' . $context['id_member'] . ';area=showalerts;do=remove;aid=' . $id . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
544 | 544 | 'javascript' => 'class="you_sure"', |
545 | 545 | 'icon' => 'remove_button' |
546 | 546 | ), |
547 | 547 | 'mark' => array( |
548 | 548 | 'label' => $alert['is_read'] != 0 ? $txt['mark_unread'] : $txt['mark_read_short'], |
549 | - 'href' => $scripturl.'?action=profile;u='.$context['id_member'].';area=showalerts;do='.($alert['is_read'] != 0 ? 'unread' : 'read').';aid='.$id.';'.$context['session_var'].'='.$context['session_id'], |
|
549 | + 'href' => $scripturl . '?action=profile;u=' . $context['id_member'] . ';area=showalerts;do=' . ($alert['is_read'] != 0 ? 'unread' : 'read') . ';aid=' . $id . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
550 | 550 | 'icon' => $alert['is_read'] != 0 ? 'unread_button' : 'read_button', |
551 | 551 | ), |
552 | 552 | 'quickmod' => array( |
553 | - 'content' => '<input type="checkbox" name="mark['.$id.']" value="'.$id.'">', |
|
553 | + 'content' => '<input type="checkbox" name="mark[' . $id . ']" value="' . $id . '">', |
|
554 | 554 | 'show' => $context['showCheckboxes'] |
555 | 555 | ) |
556 | 556 | ); |
@@ -963,20 +963,20 @@ discard block |
||
963 | 963 | $context['posts'][$key]['quickbuttons'] = array( |
964 | 964 | 'reply' => array( |
965 | 965 | 'label' => $txt['reply'], |
966 | - 'href' => $scripturl.'?action=post;topic='.$post['topic'].'.'.$post['start'], |
|
966 | + 'href' => $scripturl . '?action=post;topic=' . $post['topic'] . '.' . $post['start'], |
|
967 | 967 | 'icon' => 'reply_button', |
968 | 968 | 'show' => $post['can_reply'] |
969 | 969 | ), |
970 | 970 | 'quote' => array( |
971 | 971 | 'label' => $txt['quote_action'], |
972 | - 'href' => $scripturl.'?action=post;topic='.$post['topic'].'.'.$post['start'].';quote='.$post['id'], |
|
972 | + 'href' => $scripturl . '?action=post;topic=' . $post['topic'] . '.' . $post['start'] . ';quote=' . $post['id'], |
|
973 | 973 | 'icon' => 'quote', |
974 | 974 | 'show' => $post['can_quote'] |
975 | 975 | ), |
976 | 976 | 'remove' => array( |
977 | 977 | 'label' => $txt['remove'], |
978 | - 'href' => $scripturl.'?action=deletemsg;msg='.$post['id'].';topic='.$post['topic'].';profile;u='.$context['member']['id'].';start='.$context['start'].';'.$context['session_var'].'='.$context['session_id'], |
|
979 | - 'javascript' => 'data-confirm="'.$txt['remove_message'].'" class="you_sure"', |
|
978 | + 'href' => $scripturl . '?action=deletemsg;msg=' . $post['id'] . ';topic=' . $post['topic'] . ';profile;u=' . $context['member']['id'] . ';start=' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id'], |
|
979 | + 'javascript' => 'data-confirm="' . $txt['remove_message'] . '" class="you_sure"', |
|
980 | 980 | 'icon' => 'remove_button', |
981 | 981 | 'show' => $post['can_delete'] |
982 | 982 | ) |