Rectangle 27 0

php how to use control cache headers?


So what your saying is, it is possible to cache "images, CSS, scripts, etc." using this method without having to modify server configs?

The key is must-revalidate: This means, that the client is asking the server if the file has changed. If you dont handle this case, the browser will fetch a new copy.

This answer is wrong - the header provided will force caching of the content if implemented properly.

Yes, static files are handled by the server. Executable files (PHP, SSI, CGI) have to do this on their own, because the server cannot know, what content they produce.