On Wednesday 19 Jun 2002 4:27 am, Wei He wrote:
On Tue, 18 Jun 2002, Dieter Maurer wrote:
Wei He writes:
... 2. From the website developers' point of view, there are already many guidlines on how to create a good webpage. Among them are using the HTTP Last-modification header to take the advantages of client cache.
I think you overestimate the importance of accurate "Last-Modified" headers.
The only thing Last-Modified can give you over Expires and Cache-Control is the possibility of sending a 304 Not Modified response code instead of a 200. If the response is cheap to calculate and transmit then a 200 may not be much more expensive than a 304, and you are correct that maintaining an accurate last-modified may not be cost-effective. However, if the response is expensive to transfer (that is, large) or expensive to calculate, then a 304 may be a significant saving.
Perhaps. But I think Etag, If-Modified-Since or whatever headers only make sense to a cache server that is designed to use these values, not for a generic one or the end users browser clients.
No, these headers are specified in RFC2616 and are commonly used by browsers, caches, and accelerators.
If I understand correctly, the Expires header can only give the client an impression how ofter a page is updated.
No, it is the opposite of that. It says how long you can assume it will not change.
I would use "Expires" and "Cache-Control" for cache control.
Only when you want to disable the cache function, can these two headers be useful.
I suggest you read RFC2616.