2

我已经使用 jsp 开发了一个 Web 应用程序,当用户尝试注销时,即使我使用过会话也不会清除session.invalidate()session.removeAttribute("username"); session.removeAttribute("type");当我按下浏览器的后退按钮时,它会重定向到用户的上一页。

我的注销代码是

<%
  session.removeAttribute("username");
  session.removeAttribute("type");
  session.removeAttribute("Data");
  session.invalidate();
  response.sendRedirect("Login.jsp"); 
%>

提前致谢.....

4

0 回答 0