public function end() { $sessionVal = empty($_SESSION['IDKey']) ? '' : $_SESSION['IDKey']; $loginNHVBSRdb = new loginNHVBSRmodel(); $loginNHVBSRdb->deactivateSession($sessionVal, 'A'); $_SESSION['LOGIN.info'] = "You are successfully logged off ! "; session_destroy(); $this->registry->template->showlogon('session', 'LoginNHVBSR'); }
public function checkActiveSession($sessionKey) { $loginNHVBSRdb = new loginNHVBSRmodel(); $sessionResult = $loginNHVBSRdb->checkSessionDetails($sessionKey, 'A'); if (isset($sessionResult[0]) && $sessionResult != NULL) { return true; } else { $_SESSION['Login.Error'] = "Please Login with valid Credentails first"; session_destroy(); $this->registry->template->showlogon('session', 'LoginNHVBSR'); } }