I am trying to "cache" some png images that end with adbanner.png. What is the syntax to expire those images with *adbanner.png?
I ran the gtmetrix aginst my site and the waterfall is still showing those images taking time to load up....
Jim
do you mean via htaccess ?
make sure the mod_expires is active
one month = 2592000 seconds
<IfModule mod_expires.c>
ExpiresActive On
</IfModule>
<Files "something.png">
ExpiresActive On
ExpiresDefault A2592000
</Files>
and here is another tip if your not already using add this to the top(1st line) of your page if it is php often a miracle worker and reduces load by 60-80%..
<? ob_start("ob_gzhandler");?>
or better if your server likes it
<?php if (substr_count($_SERVER['HTTP_ACCEPT_ENCODING'], 'gzip')) ob_start("ob_gzhandler"); else ob_start(); ?>
this is what I use in almost any PHP site I work with.
GZIP works well but it is an additional load on your server compressing and then uncompressing and so on
Brian