Example #1
0
            if ($M['mod_stick'] == "1") {
                $chk_stick = "checked";
            } else {
                $chk_stick = "";
            }
            $moderators->set_var('id', $M['mod_id']);
            if ($filtermode == 'group') {
                $moderators->set_var('name', DB_getItem($_TABLES['groups'], 'grp_name', "grp_id='{$M['mod_groupid']}'"));
            } else {
                $moderators->set_var('name', $M['mod_username']);
            }
            $moderators->set_var('forum', DB_getItem($_TABLES['forum_forums'], "forum_name", "forum_id={$M['mod_forum']}"));
            $moderators->set_var('delete_yes', $chk_delete);
            $moderators->set_var('ban_yes', $chk_ban);
            $moderators->set_var('edit_yes', $chk_edit);
            $moderators->set_var('move_yes', $chk_move);
            $moderators->set_var('stick_yes', $chk_stick);
            $moderators->set_var('cssid', $i % 2 + 1);
            $moderators->parse('moderator_records', 'mod_record', true);
            $i++;
        }
        $moderators->set_var('gltoken_name', CSRF_TOKEN);
        $moderators->set_var('gltoken', SEC_createToken());
        $moderators->parse('output', 'moderators');
        $display .= $moderators->finish($moderators->get_var('output'));
    }
}
$display .= COM_endBlock();
$display .= adminfooter();
$display = COM_createHTMLDocument($display);
COM_output($display);
Example #2
0
} else {
    $theforum = '';
}
if ($op == '') {
    $bannedsql = DB_query("SELECT * FROM {$_TABLES['gf_banned_ip']} ORDER BY host_ip DESC");
    $bannum = DB_numRows($bannedsql);
    $p = new Template($_CONF['path_layout'] . 'forum/layout/admin');
    $p->set_file(array('page' => 'banip_mgmt.thtml', 'records' => 'ip_records.thtml'));
    if ($bannum == 0) {
        $p->set_var('alertmessage', $LANG_GF96['noips']);
        $p->set_var('showalert', '');
    } else {
        $p->set_var('showalert', 'none');
    }
    $p->set_var('phpself', $_CONF['site_admin_url'] . '/plugins/forum/ips.php');
    $p->set_var('LANG_IP', $LANG_GF96['ipbanned']);
    $p->set_var('LANG_Actions', $LANG_GF01['ACTIONS']);
    $i = 1;
    while ($A = DB_fetchArray($bannedsql)) {
        $p->set_var('ip', $A['host_ip']);
        $p->set_var('unban', $LANG_GF96['unban']);
        $p->set_var('csscode', $i);
        $p->parse('ip_records', 'records', true);
        $i = $i == 1 ? 2 : 1;
    }
    $p->parse('output', 'page');
    echo $p->finish($p->get_var('output'));
}
echo COM_endBlock();
echo adminfooter();
echo COM_siteFooter();
Example #3
0
// | Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.           |
// +---------------------------------------------------------------------------+
if (strpos(strtolower($_SERVER['PHP_SELF']), 'gf_functions.php') !== false) {
    die('This file can not be used on its own.');
}
require_once '../../../lib-common.php';
if (!in_array('forum', $_PLUGINS)) {
    echo COM_refresh($_CONF['site_url'] . '/index.php');
    exit;
}
/**
* Security check to ensure user even belongs on this page
*/
require_once '../../auth.inc.php';
if (!SEC_hasRights('forum.edit')) {
    $display = COM_showMessageText($MESSAGE[29], $MESSAGE[30]) . adminfooter();
    $display = COM_createHTMLDocument($display, array('pagetitle' => $MESSAGE[30]));
    COM_accessLog("User {$_USER['username']} tried to illegally access the links administration screen.");
    COM_output($display);
    exit;
}
gf_updateSystem();
require_once $_CONF['path_system'] . 'classes/navbar.class.php';
$navbar = new navbar();
$navbar->add_menuitem($LANG_GF06['1'], $_CONF['site_admin_url'] . '/plugins/forum/index.php');
$navbar->add_menuitem($LANG_GF06['3'], $_CONF['site_admin_url'] . '/plugins/forum/boards.php');
$navbar->add_menuitem($LANG_GF06['4'], $_CONF['site_admin_url'] . '/plugins/forum/mods.php');
$navbar->add_menuitem($LANG_GF06['5'], $_CONF['site_admin_url'] . '/plugins/forum/migrate.php');
$navbar->add_menuitem($LANG_GF06['6'], $_CONF['site_admin_url'] . '/plugins/forum/messages.php');
$navbar->add_menuitem($LANG_GF06['7'], $_CONF['site_admin_url'] . '/plugins/forum/ips.php');
$navbar->add_menuitem($LANG_GF06['2'], $_CONF['site_admin_url'] . '/plugins/forum/settings.php');