View Full Version : non caching web pages
is there any way to specify on a html/php page that you dont want it saved in the temp files? like a script or something that stops it being saved in the users temp files folder.
i'm using sessions and my pages are all messing up because rather than behaving real time, the info is being used thats in the temp files folder.
hope someone can help me on this one.
or does anyone have a javascript to put in a page to make sure it reloads itself rather than loading itself from the temp internet files folder?
Dr. Web
02-04-2003, 11:22 AM
though there is a meta tag for this:
<META HTTP-EQUIV="expires" CONTENT="Tue, 02 Sep 1972 12:00:00 GMT">
<META HTTP-EQUIV="pragma" CONTENT="no-cache">
however results with either line (or both) have been questionable. When you write a server side site, you should use whatever no-cache code for it.
Also, note: This does not stop the use if the cache if you hit the back button.
the following php code does it :)
<?php
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
// always modified
header("Cache-Control: no-store, no-cache, must-revalidate"); // HTTP/1.1
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache"); // HTTP/1.0
?>
Jon Hanlon
02-04-2003, 05:37 PM
See the following Knowledge Base article:
HOWTO: Prevent Caching in Internet Explorer
(http://support.microsoft.com/default.aspx?scid=kb;en-us;Q234067)
vBulletin® v3.6.7, Copyright ©2000-2009, Jelsoft Enterprises Ltd.