Re: Caching

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

> I started caching some of the static files on my application,
> I was wondering - Lets say I have an article on my website and I *want* to
> cache it. How will I cache it AND will be able to make my visitors
> "re-cache" it if it has been changed?

Work from the last modified date/time on the file. When you update the
file it will change. Though if your files really are static, then
there's little point - the OS will do a far better job of caching them
than you will.

Also, you may also want to have a goosey at the Cache-Control: HTTP
header over Expires:. It can give you more control.

> How do I use *Header set Expires* (on htaccess) and specifying "in a week"?

A quick Google found this:

Header set Expires "Thu, 15 Apr 2010 20:00:00 GMT"

-- 
Richard Heyes

HTML5 Canvas graphing for Firefox, Chrome, Opera and Safari:
http://www.rgraph.net (Updated March 28th)

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux