[thelist] Uncaching content

Kevin Martin evolt at brasscannon.net
Tue Apr 25 12:59:36 CDT 2006


Since we're sort of on the subject...  I tossed up a trivial webcam
page (state of the art for 1996) that should update several times
a day, but for some reason none of the "Don't cache this!" tricks
I've applied seem to work.  I still see the old pictures long after
they've been replaced on the server.

I went to some effort to rotate the filenames in place, as though
they were log files.  Do I really have to generate an infinite
series of new names instead?  

Don't-cache-this tips I've tried so far:

 - PHP sends a Cache-control header before the HTML to
   turn off AOL's caching proxy.

 - meta-equiv headers to set Expires to "long ago", Pragma no-cache,
   and CacheControl no-cache.

 - Per Microsoft's advice, I'm sending a SECOND "head" section after
   the body with all the same items again, since IE may have discarded
   the first set to make room for the image data. ("You've GOT to be 
   kidding!"  No, they really said that.)

 Cache-Control: no-store  <!-- http header sent by PHP -->
 <html><head>
 <meta name="ROBOTS" content="NONE">
 <meta http-equiv="Expires" content="Mon, 04 Dec 1999 21:29:02 GMT">
 <meta http-equiv="Pragma" content="no-cache">
 <meta http-equiv="CacheControl" content="no-cache">
 <title>HOMECAM</title></head>
 <body bgcolor=black><center>
 <!-- bunch of thumbnails as links -->
 </body>
 <head>
 <meta http-equiv="Expires" content="Mon, 04 Dec 1999 21:29:02 GMT">
 <meta http-equiv="Pragma" content="no-cache">
 <meta http-equiv="CacheControl" content="no-cache">
 </head></html>

What else IS there?

Thanks in advance....




More information about the thelist mailing list