jsp页面清除缓存

1.服务端方法

<%    
response.setHeader("Pragma","No-cache");     
response.setHeader("Cache-Control","no-cache");     
response.setDateHeader("Expires", -10);    
%>  

2.客服端方法

在head中加入

<html> 
<head> 
<meta http-equiv="Expires" CONTENT="0"> 
<meta http-equiv="Cache-Control" CONTENT="no-cache"> 
<meta http-equiv="Pragma" CONTENT="no-cache"> 
</head>

posted @ 2013-04-03 10:17  流星焱雨  阅读(312)  评论(0编辑  收藏  举报