I have several pages with many small images that almost never change. I've noticed that much of my page load time is just sending and receiving headers. Rather than having the browser make a request for every item on every single refresh and receive a bunch of "304 not modified" responses, I'd like the browser to default to it's cache instead. I've read around, and implemented the following in my apache config file:
Code: Select all
ExpiresActive On
<FilesMatch "\.(gif|jpg|jpeg|png|js|css|pdf)$">
Header set Cache-Control max-age=86400
# Header set ExpiresDefault "access plus 1 day"
</FilesMatch>