getUserArray($session, 1);
if (!$admin || (int)$admin['access'] !== 9) {
die('
Access Denied: You are not Admin!
');
}
// ---------------------------------------------------------------------------
// Reset Plus
// ---------------------------------------------------------------------------
$database->query("UPDATE " . TB_PREFIX . "users SET plus = 0 WHERE id > 0");
// ---------------------------------------------------------------------------
// Log admin
// ---------------------------------------------------------------------------
$adminId = (int)$_SESSION['id'];
$time = time();
$logText = "Reset Plus to 0 for all users";
$logEsc = $database->escape($logText);
$database->query(
"INSERT INTO " . TB_PREFIX . "admin_log (`id`, `user`, `log`, `time`) " .
"VALUES (0, '$adminId', '$logEsc', $time)"
);
header("Location: ../../../Admin/admin.php?p=maintenenceResetPlus&g=1");
exit;
?>