/** * 用户登出 */ public function logout() { try { lib()->load('UserLogin'); UserLogin::Logout(); $this->rt_msg['status'] = true; } catch (\Exception $ex) { $this->rt_msg['msg'] = $ex->getMessage(); } }
public function logout() { try { lib()->load('UserLogin'); UserLogin::Logout(); redirect(); } catch (\Exception $ex) { $this->theme->setTitle("登出失败"); $this->__view("Home/header.php"); $this->__view("Home/logout_error.php"); $this->__view("Home/footer.php"); } }