CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> Archive -> CodeChargeStudio.Discussion

 Caching Problem - PHP

Print topic Send  topic

Author Message
Freddie
Posted: 03/28/2003, 2:36 PM

I am using PHP with Tomcat. All my pages keep on caching the data that gets
displayed.

I have found the following php code:
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

I have added this code to the beginning of my html page and also tried it
in the corresponding html's generated ".php" page. It does not seem to
work, the data still gets cached. Where should I put this code, or is there
any other ways of solving the problem.

Thanks
Freddie




   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.