define('CCMS_PERFORM_MINIMAL_INIT', true); } // Compress all output and coding header('Content-type: text/html; charset=UTF-8'); // Define default location if (!defined('BASE_PATH')) { $base = str_replace('\\', '/', dirname(dirname(__FILE__))); define('BASE_PATH', $base); } // Include general configuration /*MARKER*/ require_once BASE_PATH . '/lib/sitemap.php'; /* make darn sure only authenticated users can get past this point in the code */ if (empty($_SESSION['ccms_userID']) || empty($_SESSION['ccms_userName']) || !checkAuth()) { // this situation should've caught inside sitemap.php-->security.inc.php above! This is just a safety measure here. die_with_forged_failure_msg(__FILE__, __LINE__); // $ccms['lang']['auth']['featnotallowed'] } $status = getGETparam4IdOrNumber('status'); $status_message = getGETparam4DisplayHTML('msg'); // Get the number of users; this is used to dimension some user management window(s); also count INactive users! $user_count = $db->SelectSingleValue($cfg['db_prefix'] . 'users', null, 'COUNT(userID)'); if ($db->ErrorNumber()) { $db->Kill(); } $total_page_count = $db->SelectSingleValue($cfg['db_prefix'] . 'pages', null, 'COUNT(page_id)'); if ($db->ErrorNumber()) { $db->Kill(); } ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
$total = isset($_POST['userID']) ? count($_POST['userID']) : 0; if ($total == 0) { throw new FbX($ccms['lang']['system']['error_selection']); } // Delete details from the database $i = 0; foreach ($_POST['userID'] as $user_num) { $user_num = filterParam4Number($user_num); $values = array(); // [i_a] make sure $values is an empty array to start with here $values['userID'] = MySQL::SQLValue($user_num, MySQL::SQLVALUE_NUMBER); $result = $db->DeleteRows($cfg['db_prefix'] . 'users', $values); $i++; } // Check for errors if ($result && $i == $total) { header('Location: ' . makeAbsoluteURI('user-management.Manage.php?status=notice&msg=' . rawurlencode($ccms['lang']['backend']['fullremoved']))); exit; } else { throw new FbX($db->MyDyingMessage()); } } else { throw new FbX($ccms['lang']['auth']['featnotallowed']); } } catch (CcmsAjaxFbException $e) { $e->croak(); } } // when we get here, an illegal command was fed to us! die_with_forged_failure_msg(__FILE__, __LINE__, "do_action={$do_action}, checkAuth=" . 1 * checkAuth());