`
Yarhhome
  • 浏览: 47696 次
  • 性别: Icon_minigender_1
  • 来自: 广州
最近访客 更多访客>>
社区版块
存档分类
最新评论
  • Yarhhome: tpsnake 写道大哥,你的帖子没让我折服,你的 头像让我折 ...
    禁止缓存
  • tpsnake: 大哥,你的帖子没让我折服,你的 头像让我折服了
    禁止缓存

禁止缓存

阅读更多

 

HTML: 
在HtML代码中加入 
<HEAD> 
<META HTTP-EQUIV="Pragma" CONTENT="no-cache"> 
<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache"> 
<META HTTP-EQUIV="Expires" CONTENT="0"> 
</HEAD> 

ASP 
response.expires=0 
response.addHeader("pragma","no-cache") 
response.addHeader("Cache-Control","no-store, must-revalidate") 

PHP 
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); 
header("Cache-Control: no-store, must-revalidate"); 
header("Pragma: no-cache"); 

JSP: 
response.addHeader("Cache-Control", "no-store, must-revalidate"); 
response.addHeader("Expires", "Thu, 01 Jan 1970 00:00:01 GMT");

 

分享到:
评论
2 楼 Yarhhome 2013-11-19  
tpsnake 写道
大哥,你的帖子没让我折服,你的 头像让我折服了

哈哈 ,帅不帅
1 楼 tpsnake 2012-08-20  
大哥,你的帖子没让我折服,你的 头像让我折服了

相关推荐

Global site tag (gtag.js) - Google Analytics