This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes JSP and the fly likes Cache control in IE Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Cache control in IE" Watch "Cache control in IE" New topic
Author

Cache control in IE

zeberga Amerga
Greenhorn

Joined: Jul 13, 2004
Posts: 1
Hi Everyone,

I'm having a problem having IE not cache jsp pages. I'm using this 4 lines at the begining of my jsp but IE still caches the page.

response.setHeader("Cache-Control","no-cache"); //http 1.0
response.setHeader("Cache-Control", "no-cache, no-store, must-revalidate");//http 1.1
response.setHeader("Pragma","no-cache");
response.setHeader("Expires", "01 Apr 1995 01:10:10 GMT");

I really appreciate your sugestions.

Thanks
Zeb
Jeroen Wenting
Ranch Hand

Joined: Oct 12, 2000
Posts: 5093
most likely it's a proxy server somewhere that does the caching...
IE is pretty decent, many proxies are not.

You can try response.setDateHeader("Expires", 0); and see if that works.


42
 
Have you checked out Aspose?
 
subject: Cache control in IE
 
It's not a secret anymore!