php禁止页面缓存的办法

//设置此页面的过期时间(用格林威治时间表示),只要是已经过去的日期即可。

add_header Expires: Mon, 26 Jul 1997 05:00:00 GMT ;

//设置此页面的最后更新日期(用格林威治时间表示)为当天,可以强制浏览器获取最新资料

add_header Last-Modified: ' . gmdate('D, d M Y H:i:s').' GMT ;

//告诉客户端浏览器不使用缓存,HTTP 1.1 协议

add_header Cache-Control: no-cache, must-revalidate;

//告诉客户端浏览器不使用缓存,兼容HTTP 1.0 协议

add_header Pragma: no-cache ;

 

 

ASP禁止页面缓存的办法

add_header expires=0
add_header Pragma "no-cache";

add_header Cache-Control no-cache must-revalidate;

JSP禁止页面缓存的办法

add_header Cache-Control no-cache;

add_header Expires "Thu, 01 Jan 1970 00:00:01 GMT";

 

相关文章:

  • 2021-08-26
  • 2021-09-13
  • 2021-09-08
  • 2021-08-05
  • 2021-10-01
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-11-29
  • 2022-01-13
  • 2022-02-06
  • 2022-12-23
  • 2021-11-26
  • 2021-10-06
相关资源
相似解决方案