Forum Moderators: coopster

Message Too Old, No Replies

caching

         

hermes

12:14 am on Jan 1, 2005 (gmt 0)

10+ Year Member



Hi guys,

I am having some problems with the control of caching. For instance take this webpage:

<?php
header("Cache-Control: no-store, no-cache");
echo 'hello world';
?>

As I underastand it this should not be cached by Internet explorer. And yet it is on my system. What have I done wrong?

I can find it in my Temp Internet Files. If I go:

Internet options
Temporary Internet Files
Settings
View files

It is in there teasing and laughing at me. How can I adjust the file to stop it being cached in this way.

Also, consider the file:

<?php
echo 'hello world';
?>

Now, no header. But, from my reading I have been led to belive that a page such as this, with a .php extension, should not be cached by Internet explorer anyway. Yet it is still cached. Why is this?

Would really appreciate some advice. I dont know where i am going wrong.

ergophobe

5:13 pm on Jan 1, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



This works for me

header("Cache-Control: no-store, no-cache, must-revalidate");
header("Pragma: no-cache");