note 27115 deleted from function.header by sniper
| From: | sniper@php.net | Date: | Sun, 07 Sep 2003 21:37:04 +0000 |
| Subject: | note 27115 deleted from function.header by sniper | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-55629@lists.php.net to get a copy of this message | ||
Note Submitter:
----
I actually want content to be cached for the next 30 days after it has been downloaded. I am not an
expert on the HTTP protocol - but I thik this will work:
$ts = date('D, d M Y H:i:s T',
gmmktime(0,0,0,gmdate("m"),(gmdate("d")+30),gmdate("Y")));
header("Expires: $ts"); // Date 30 days time;
header("Cache-Control: max-age=2592000, min-fresh=2592000, max-stale=0"); // HTTP/1.1