Php Expires Header

From EggeWiki
Revision as of 05:45, 19 July 2009 by Egge (talk | contribs) (Created page with 'Add an expires header to cause the page to expire in 24 hours. <geshi lang="php"> $offset = 60 * 60 * 24; $ExpStr = "Expires: " . gmdate("D, d M Y H:i:s", time() + $offset) . "…')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Add an expires header to cause the page to expire in 24 hours.

<geshi lang="php"> $offset = 60 * 60 * 24; $ExpStr = "Expires: " . gmdate("D, d M Y H:i:s", time() + $offset) . " GMT"; header($ExpStr); </geshi>