禁止用户后退好象不可能吧,但是可以让后退的时候把页面刷新是可以做到的。下面的代码就可以实现!!!!
<%
response.setHeader("Pragma","No-cache");
response.setHeader("Cache-Control","no-cache");
response.setDateHeader("Expires", 0);
%>
<%
response.setHeader("Pragma","No-cache");
response.setHeader("Cache-Control","no-cache");
response.setDateHeader("Expires", 0);
%>
解决方案 »
- myeclipse连接mysql数据库出现问题
- 数据处理,数据变向
- 用js验证表单中所有的控件项
- 请高手帮我 解决一下这个页面的错误~!谢谢~!
- ELException
- 求救:tomcat和sql server2000连接出现NullPointerException问题!急!!
- 配置数据源后,为何无法加载数据库驱动程序?
- 为什么我不能用session存放数字?比如session.setAttribute("times",1),这样会出错!!
- 如何将javascript函数的参数传递给jsp使用?
- 一个关于ejb打包和部署的简单问题
- 类似chinaren中同学录里的班级相册那中页子是如何做的.?
- 一个简单但是让我无法理解的问题,请教各位!
next url http://abc.com.a
next url http://abc.com.b<form method="post" action="http://abc.com.a" name="myform">
</form><script>
gotolink(){ document.myform.submit();}
</script><a href="javascript:gotolink()">click to go</a>In every servlet,u can use doPost method instead of the doGet method.It may work,but I never try.