I have recently analysed my website with pagespeed addon on firebug. It suggested me to set expiration on CSS, JS and image files.
I am wondering how do i do this?
I have recently analysed my website with pagespeed addon on firebug. It suggested me to set expiration on CSS, JS and image files.
I am wondering how do i do this?
i would like to add this solution for those searching for it....
its also works great...using
.htaccess
https://webmasters.stackexchange.com/a/5275/37765
What I do is to create a file "expires.conf" and include it in the site file configuration of Apache. You can include in .htaccess if you want. My expires:
You need to activate the expires module in apache.
Better one (found at http://www.paulund.co.uk/set-expire-headers-in-htaccess, but as
0 seconds
didnt work, I've changed it to1 seconds
)This is the one I use to fix the exact same thing when I ran the PageSpeed Addon:
This goes into your .htaccess file.
Read up on this page for more information about how to set cache for additional file types and/or change the cache length:
http://www.askapache.com/htaccess/apache-speed-cache-control.html