Home >Database >Mysql Tutorial >按IE后退按钮时让JSP不读缓存_MySQL

按IE后退按钮时让JSP不读缓存_MySQL

WBOY
WBOYOriginal
2016-06-01 14:10:58861browse

  
在ASP里我曾告诉过朋友如何让ASP程序不从缓存里读取数据,同样在JSP里也能实现,请看下面:



1, 使用java提供的方法,在jsp或者servlet中都可以 
response.setHeader("Pragma","No-cache"); 
response.setHeader("Cache-Control","no-cache"); 
response.setDateHeader("Expires", 0); 
%> 
2, 使用HTML标记,如下面: 

 
 
 
 

 
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn