'; $alternate = true; // Show all the blocks they want to see. foreach ($context['mod_blocks'] as $block) { $block_function = 'template_' . $block; echo '
', function_exists($block_function) ? $block_function() : '', '
'; if (!$alternate) echo '
'; $alternate = !$alternate; } echo '
'; } // Show all the group requests the user can see. function template_group_requests_block() { global $context, $txt, $scripturl; echo '

', $txt['mc_group_requests'], '

'; } // A block to show the current top reported posts. function template_reported_posts_block() { global $context, $txt, $scripturl; echo '

', $txt['mc_recent_reports'], '

'; } function template_watched_users() { global $context, $txt, $scripturl; echo '

', $txt['mc_watched_users'], '

'; } // Little section for making... notes. function template_notes() { global $settings, $context, $txt, $scripturl; echo '

', $txt['mc_notes'], '

'; if (!empty($context['notes'])) { echo '
    '; // Cycle through the notes. foreach ($context['notes'] as $note) echo '
  • ', $note['time'] ,' ', $note['author']['link'], ': ', $note['text'], '
  • '; echo '
', $context['page_index'], '
'; } echo '
'; } function template_reported_posts() { global $context, $txt, $scripturl; // Let them know the action was a success. if (!empty($context['report_post_action']) && !empty($txt['report_action_'. $context['report_post_action']])) { echo '
', $txt['report_action_'. $context['report_post_action']], '
'; } echo '

', $context['view_closed'] ? $txt['mc_reportedp_closed'] : $txt['mc_reportedp_active'], '

'; // Make the buttons. $close_button = create_button('close.png', $context['view_closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', $context['view_closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', 'class="centericon"'); $details_button = create_button('details.png', 'mc_reportedp_details', 'mc_reportedp_details', 'class="centericon"'); $ignore_button = create_button('ignore.png', 'mc_reportedp_ignore', 'mc_reportedp_ignore', 'class="centericon"'); $unignore_button = create_button('ignore.png', 'mc_reportedp_unignore', 'mc_reportedp_unignore', 'class="centericon"'); $ban_button = create_button('close.png', 'mc_reportedp_ban', 'mc_reportedp_ban', 'class="centericon"'); $delete_button = create_button('delete.png', 'mc_reportedp_delete', 'mc_reportedp_delete', 'class="centericon"'); foreach ($context['reports'] as $report) { echo '
', !empty($report['topic']['board_name']) ? '' . $report['topic']['board_name'] . '' : '??', ' / ', $report['subject'], ' ', $txt['mc_reportedp_by'], ' ', $report['author']['link'], '
', $txt['mc_reportedp_last_reported'], ': ', $report['last_updated'], ' - '; // Prepare the comments... $comments = array(); foreach ($report['comments'] as $comment) $comments[$comment['member']['id']] = $comment['member']['link']; echo ' ', $txt['mc_reportedp_reported_by'], ': ', implode(', ', $comments), '

', $report['body'], '
'; } // Were none found? if (empty($context['reports'])) echo '

', $txt['mc_reportedp_none_found'], '

'; echo '
', !$context['view_closed'] ? '' : '', '
'; } // Show a list of all the unapproved posts function template_unapproved_posts() { global $options, $context, $txt, $scripturl; // Just a big table of it all really... echo '

', $txt['mc_unapproved_posts'], '

'; // Make up some buttons $approve_button = create_button('approve.png', 'approve', 'approve', 'class="centericon"'); $remove_button = create_button('delete.png', 'remove_message', 'remove', 'class="centericon"'); // No posts? if (empty($context['unapproved_items'])) echo '

', $txt['mc_unapproved_' . $context['current_view'] . '_none_found'], '

'; else echo '
', $context['page_index'], '
'; foreach ($context['unapproved_items'] as $item) { echo '
', $item['counter'], '
', $item['category']['link'], ' / ', $item['board']['link'], ' / ', $item['link'], '
', $txt['mc_unapproved_by'], ' ', $item['poster']['link'], ' ', $txt['on'], ': ', $item['time'], '
', $item['body'], '
', $approve_button, ''; if ($item['can_delete']) echo ' ', $context['menu_separator'], ' ', $remove_button, ''; if (!empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1) echo ' '; echo '
'; } echo '
'; if (!empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1) echo '
'; if (!empty($context['unapproved_items'])) echo '
'; echo '
'; } function template_viewmodreport() { global $context, $scripturl, $txt; echo '

', sprintf($txt['mc_viewmodreport'], $context['report']['message_link'], $context['report']['author']['link']), '

', sprintf($txt['mc_modreport_summary'], $context['report']['num_reports'], $context['report']['last_updated']), ' '; // Make the buttons. $close_button = create_button('close.png', $context['report']['closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', $context['report']['closed'] ? 'mc_reportedp_open' : 'mc_reportedp_close', 'class="centericon"'); $ignore_button = create_button('ignore.png', 'mc_reportedp_ignore', 'mc_reportedp_ignore', 'class="centericon"'); $unignore_button = create_button('ignore.png', 'mc_reportedp_unignore', 'mc_reportedp_unignore', 'class="centericon"'); echo ' ', $context['report']['ignore'] ? $unignore_button : $ignore_button, ' ', $close_button, '

', $context['report']['body'], '

', $txt['mc_modreport_whoreported_title'], '

'; foreach ($context['report']['comments'] as $comment) echo '

', sprintf($txt['mc_modreport_whoreported_data'], $comment['member']['link'] . (empty($comment['member']['id']) && !empty($comment['member']['ip']) ? ' (' . $comment['member']['ip'] . ')' : ''), $comment['time']), '

', $comment['message'], '

'; echo '

', $txt['mc_modreport_mod_comments'], '

'; if (empty($context['report']['mod_comments'])) echo '

', $txt['mc_modreport_no_mod_comment'], '

'; foreach ($context['report']['mod_comments'] as $comment) echo '

', $comment['member']['link'], ': ', $comment['message'], ' (', $comment['time'], ')

'; echo '

'; $alt = false; template_show_list('moderation_actions_list'); echo '
'; } // Callback function for showing a watched users post in the table. function template_user_watch_post_callback($post) { global $scripturl, $context, $txt, $delete_button; // We'll have a delete please bob. if (empty($delete_button)) $delete_button = create_button('delete.png', 'remove_message', 'remove', 'class="centericon"'); $output_html = '
' . $post['subject'] . ' ' . $txt['mc_reportedp_by'] . ' ' . $post['author_link'] . '
'; if ($post['can_delete']) $output_html .= ' ' . $delete_button . ' '; $output_html .= '

« ' . $txt['mc_watched_users_posted'] . ': ' . $post['poster_time'] . ' »

' . $post['body']; return $output_html; } // Moderation settings function template_moderation_settings() { global $context, $txt, $scripturl; echo '
'; if ($context['can_moderate_approvals']) { echo '
:
'; } echo '

'; } // Show a notice sent to a user. function template_show_notice() { global $txt, $settings, $context; // We do all the HTML for this one! echo ' ', $context['page_title'], '

', $txt['show_notice'], '

', $txt['show_notice_subject'], ': ', $context['notice_subject'], '

', $txt['show_notice_text'], ':
', $context['notice_body'], '
'; } // Add or edit a warning template. function template_warn_template() { global $context, $txt, $scripturl; echo '

', $context['page_title'], '

', $txt['mc_warning_template_desc'], '
:
:
', $txt['mc_warning_template_body_desc'], '
'; if ($context['template_data']['can_edit_personal']) echo '
', $txt['mc_warning_template_personal_desc'], '
'; echo '
'; } ?>