首页 > 其他 > 详细

避免get缓存

时间:2015-09-17 19:09:37      阅读:196      评论:0      收藏:0      [点我收藏+]

  get请求:

1,修改url加上new Date().getTime();等同于加上?v=1;

2,在服务器加响应头

response.setContentType("text/html;charset:UTF-8");

response.addHeader("prama","no-cache");

response.addHeader("cache-control","no-cache");

response.addHeader("expires","o");

避免get缓存

原文:http://www.cnblogs.com/shininguang/p/4817002.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!