/** * Perform logout * * @return void */ public function logout() { X4Auth_helper::log_out(); setcookie(COOKIE . '_hash', '', time() - 3600, '/', $_SERVER['HTTP_HOST']); // log if (LOGS) { if (isset($_SESSION['xuid'])) { $mod = new X4Auth_model('users'); $mod->logger($_SESSION['xuid'], 1, 'users', 'log out'); } } // redirect header('Location: ' . ROOT); die; }
/** * Perform logout * * @return void */ public function logout() { // log if (LOGS) { $mod = new X4Auth_model('users'); $mod->logger($_SESSION['uid'], $_SESSION['id_area'], 'users', 'log out'); } X4Auth_helper::log_out(); // redirect header('Location: ' . ROOT); die; }