<?php

if (isset($_GET['id'])) {
    if ($_GET['id'] > 0) {
        $gid = $_GET['id'];
        if (isset($_GET['action'])) {
            if ($_GET['action'] == 'ban') {
                showBanForm($gid);
            } elseif ($_GET['action'] == 'unban') {
                unBan($gid);
            } elseif ($_GET['action'] == 'delete') {
                deleteUser($gid);
            } else {
                echo "Invalid Action";
            }
        } else {
            $profile = $Account->getProfile($_GET['id']);
            $lastvisit = date("Y-m-d, g:i a", $profile['last_visit']);
            $seebanned = $DB->count("SELECT COUNT(*) FROM account_banned WHERE id='" . $_GET['id'] . "' AND `active`=1");
            if ($seebanned > 0) {
                $bann = 1;
            } else {
                $bann = 0;
            }
            ?>

	<!-- Viewing an account -->
		<div class="content">	
			<div class="content-header">
				<h4><a href="?p=admin">Main Menu</a> / <a href="?p=admin&sub=users">Manage Users</a> / <?php 
            echo $profile['username'];
Example #2
0
/**
 * Possible actions
 */
function shoutboxActions()
{
    global $mybb;
    $action = $mybb->input['action'];
    switch ($action) {
        case 'shoutbox_reports':
            showReports();
            break;
        case 'shoutbox_banned':
            showBanned();
            break;
        case 'shoutbox_ban':
            showBanForm();
            break;
        case 'shoutbox_private':
            showPrivate();
            break;
        case 'shoutbox_unban':
            shoutboxUnban();
            break;
        default:
            return;
            break;
    }
    return;
}