Why are my obsolete headers not allowing my files to remain in the cache?

I use valid expiration dates and cache-free headers for my static files, and they remain cached for as long as I continue to browse, but when I close my browser and use it after a while, I see that the static files load again. even if not updated with ctrl (+ shift) + r

I use Firefox, the cache size is set to 250 MB, and I do not allow it to delete any private or cached data.

Headers: Accept-Ranges: byte Cache-Control: max-age = 29030400, public Content-length: 142061 Content-Type: image / png Date: Tue, 08 Dec 2009 19:18:43 GMT Expires: Tue, 09 Nov. 2010 19:18:43 GMT Last change: Sun, Jan 18. 2009 18:33:48 GMT Server: Apache / 2.2.14 (EL)

+3
source share
1 answer

What version of Firefox? Server sends Etags for static files? You can view cache information for Firefox by going to cache and poking. This will give you an idea of ​​what Firefox caches.

. , , max-age , , , Expires. . HTTP 1.1 : http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9.3.

Expires , max-age , . , HTTP/1.1 ( ), HTTP/1.0 . , HTTP/1.0 , , - .

Cache-Control, .

+2

Source: https://habr.com/ru/post/1725010/


All Articles