Forum Moderators: Robert Charlton & goodroi

Message Too Old, No Replies

"If-Modified-Since HTTP header"

please explain...anyone?

         

red_hot

12:18 pm on Nov 21, 2006 (gmt 0)

10+ Year Member



"If-Modified-Since HTTP header" ... can somebody please explain what this thing means found it on

[google.com...]

jd01

2:09 pm on Nov 21, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



An If-Modified-Since header is sent by the requesting user-agent (in the form of a time/date stamp --- Tue, Nov 21, 2006 5:55:53 AM) for comparison to see if a page has been modified and needs to be re-requested, or if the requesting user agent can load the page from the cache.

If there is a match, the page (or resource --- applies to graphics, etc.) should not be re-requested. If the server sends a different string than the requesting agent has the page should be re-downloaded from the server.

An Etag does the same thing, except it is not a time/date string it is a unique char. string assigned to a version of a page.
(It is compared with If-None-Match.)

EG
ETag: "d41d8c-d98f-0b204e98"

On the next edit to the page, a new, unique ETag should be generated, so when a requesting agent compares the string it will not match and the page will be re-requested from the server.

Header Field Definitions [w3.org]

Hope this helps.

Justin

Sorry if my techincal verbiage is not 'perfect' - still early out here.

4specs

2:37 pm on Nov 21, 2006 (gmt 0)

10+ Year Member



One more thought on E-Tags. I have header and footer includes done by php. When these includes change and the page does not, it is not necessary to download the page again.

I use php for includes and a somewhat modified program that supplies the missing 304 and if-modified-since responses. I eliminated the E-Tag response while retaining the if-modified response.