[pmwiki-users] cache control
5ko at 5ko.fr
Tue Nov 24 18:05:03 CST 2009
On Tuesday 24 November 2009 18:43:16 Daniel Otis wrote:
> I added
> $HTMLHeaderFmt['cache'] = "<meta http-equiv='Cache-Control' content='cache'
> />"; to my config.php
You shouldn't need to add this, with the next line, PmWiki will automatically
tell the browsers which have seen the page, that it wasn't modified.
> and I have
> $EnableIMSCaching = 1;
> But the headers have:
> GET / HTTP/1.1[CRLF]
> Host: www.moosoft.com[CRLF]
> Cache-Control: no[CRLF]
> Why is cache-control set to no?
It is Cache-Control: no-cache (just tested it on your server) and it is the
correct thing to do, refer to
Cache-Control: no-cache is about required validation, not about caching by the
browser, but about caching by proxies -- the browser always asks the server
if the page has changed, and if not, PmWiki sends a "304 Not modified" header
and exits. It should work on your own site, check your apache logs and you'll
have a number of 304 responses.
Note that a wiki page may include other pages, pagelists and conditional
markup. Finding the actual Last Modified timestamp of all included pages is
quite complex, so PmWiki just sends the timestamp of the latest edit of the
latest edited page in the wiki - it's simpler, even if some browsers may
download the same content twice.
More information about the pmwiki-users