Servlet 使Session设置失效

protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		request.getSession().invalidate();  // 销毁会话
		request.setAttribute("msg", "您已退出");
		request.getRequestDispatcher("login.jsp").forward(request, response);
	}

 

posted @ 2019-05-16 11:33  麦克斯-侯  阅读(783)  评论(0编辑  收藏  举报
百纵科技