[Zope] No cache headers

Peter Bengtsson mail at peterbe.com
Fri Oct 7 06:01:29 EDT 2005


This might be a FAQ but I've searched and just found a bunch of
different results. Some old and some even older.
What do you use to stop caching? IE users of my current project have
reported problems of pages on updating. I'm not setting any caching at
all so that's what IE does out of the box. (Firefox is not having a
problem).

Currently I'm using this:

now = DateTime().toZone('GMT').rfc822()
response.setHeader('Expires', now)
response.setHeader('Last-Modified', now)
response.setHeader('Cache-Control','no-cache')

By inspection with LiveHTTPHeaders in Firefox it sets them all but I'm
not 100% certain they will work.
There's also the concern that I think M$ IE might have a bug in
relation to that 'Cache-Control' header. There's some strange and now
I just can't remember it or find out about it on google.

So, what do you people use? Willing to share some of that?


--
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.com


More information about the Zope mailing list