WebPagetest Forums
Getting an F at Cache static content! - Printable Version

+- WebPagetest Forums (https://www.webpagetest.org/forums)
+-- Forum: Web Performance (/forumdisplay.php?fid=3)
+--- Forum: Discuss Test Results (/forumdisplay.php?fid=4)
+--- Thread: Getting an F at Cache static content! (/showthread.php?tid=11815)



Getting an F at Cache static content! - carllauren - 10-23-2012 06:49 PM

I have tried adding the following code to fix this error to my .htaccess, but it doesn't seem to fix anything.

## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access plus 1 year"
ExpiresByType image/jpeg "access plus 1 year"
ExpiresByType image/gif "access plus 1 year"
ExpiresByType image/png "access plus 1 year"
ExpiresByType text/css "access plus 1 month"
ExpiresByType application/pdf "access plus 1 month"
ExpiresByType text/x-javascript "access plus 1 month"
ExpiresByType application/x-shockwave-flash "access plus 1 month"
ExpiresByType image/x-icon "access plus 1 year"
ExpiresDefault "access plus 2 days"
</IfModule>
## EXPIRES CACHING ##

I am using wp supercache and mod rewrite is installed on the server (using hostgator). I am also using maxcdn!

When looking at the test result, the problem seems to be that a lot of .js files and images doesn't have any expiration date set..

How can I fix this?


RE: Getting an F at Cache static content! - pmeenan - 10-24-2012 04:52 AM

Do you have a link to your test result? There are a bunch of different mime types that get used by javascript and it's possible that your server is serving something other than text/x-javascript


RE: Getting an F at Cache static content! - carllauren - 10-24-2012 05:01 AM

(10-24-2012 04:52 AM)pmeenan Wrote:  Do you have a link to your test result? There are a bunch of different mime types that get used by javascript and it's possible that your server is serving something other than text/x-javascript

I actually forgot to clear the cache from maxcdn, now I am scoring a C. It's only twitter and facebook stuff left, but I guess those are hard to fix?

Here is my test. Is there anything more I can improve?


RE: Getting an F at Cache static content! - pmeenan - 10-26-2012 02:54 AM

If you can, check you embed method for the various different social networks. Looks like all of them are downloading multiple times, for each button with each story. Most of them should have a way to only load once but target multiple buttons on the page.