加以下的代码
<%
response.setHeader("Pragma","no-cache");
response.setHeader("Cache-Control","no-cache");
response.setDateHeader("Expires",0);
%>
<META HTTP-EQUIV="Pragma" CONTENT="no-Cache">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-Cache">
<META HTTP-EQUIV="Expires" CONTENT="0">
<%
response.setHeader("Pragma","no-cache");
response.setHeader("Cache-Control","no-cache");
response.setDateHeader("Expires",0);
%>
<META HTTP-EQUIV="Pragma" CONTENT="no-Cache">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-Cache">
<META HTTP-EQUIV="Expires" CONTENT="0">
具体方法是在登录的时候在客户端添加一个cookie,注销的时候删除该cookie,在每个页面的开始处加上一段javascript检验该cookie是否存在,如果不存在则转向到登陆页面去
只要加入这条语句即可: javascript:window.history.forward(1); 谢谢大家的发言!