function security_check_reminder() { global $_CONF, $_TABLES, $_IMAGE_TYPE, $MESSAGE; $retval = ''; if (!SEC_inGroup('Root')) { return $retval; } $done = DB_getItem($_TABLES['vars'], 'value', "name = 'security_check'"); if ($done != 1) { $retval .= COM_showMessage(92); } return $retval; } // MAIN $display = ''; if (isset($_POST['mode']) && $_POST['mode'] == 'moderation' && SEC_checkToken()) { $action = array(); if (isset($_POST['action'])) { $action = $_POST['action']; } if ($_POST['type'] == 'user') { $mod_result = moderateusers($_POST['id'], $action, COM_applyFilter($_POST['count'], true)); } else { $mod_result = moderation($_POST['id'], $action, $_POST['type'], COM_applyFilter($_POST['count'], true)); } $display .= COM_siteHeader('menu', $LANG29[34]) . COM_showMessageFromParameter() . $mod_result; } else { $display .= COM_siteHeader('menu', $LANG29[34]) . COM_showMessageFromParameter() . security_check_reminder() . commandcontrol(SEC_createToken()); } $display .= COM_siteFooter(); COM_output($display);
*/ require_once '../lib-common.php'; /** * Security check to ensure user even belongs on this page */ require_once 'auth.inc.php'; // MAIN if (isset($_GET['mode']) && $_GET['mode'] == 'logout') { print COM_refresh($_CONF['site_url'] . '/users.php?mode=logout'); } /** * Display a reminder to execute the security check script * * @return string HTML for security reminder (or empty string) */ function security_check_reminder() { global $_CONF, $_TABLES, $_IMAGE_TYPE, $MESSAGE; $retval = ''; if (!SEC_inGroup('Root')) { return $retval; } $done = DB_getItem($_TABLES['vars'], 'value', "name = 'security_check'"); if ($done != 1) { $retval .= COM_showMessage(92); } return $retval; } $display = COM_showMessageFromParameter() . security_check_reminder() . COM_commandControl(); $display = COM_createHTMLDocument($display, array('pagetitle' => $LANG29[34])); COM_output($display);
* Display a reminder to execute the security check script * */ function security_check_reminder() { global $_CONF, $_TABLES, $_IMAGE_TYPE, $MESSAGE; $retval = ''; if (!SEC_inGroup('Root')) { return $retval; } $done = DB_getItem($_TABLES['vars'], 'value', "name = 'security_check'"); if ($done != 1) { $retval .= COM_showMessage(92); } return $retval; } // MAIN $display = COM_siteHeader('menu', $LANG29[34]); $msg = COM_getMessage(); if ($msg > 0) { $plugin = ''; if (isset($_GET['plugin'])) { $plugin = COM_applyFilter($_GET['plugin']); } $display .= COM_showMessage($msg, $plugin); } $display .= _checkUpgrades(); $display .= security_check_reminder(); $display .= commandcontrol(); $display .= COM_siteFooter(); echo $display;