Welcome Guest | Login

htaccess and cache?

Hi, can I paste this in my .htaccess ffile in my rails app/public to enable my sites images to get cached on the visitors cumputer?

<FilesMatch "\.(jpg|jpeg|png|gif|swf)$">
Header set Cache-Control "max-age=2419200, public"
</FilesMatch>

2007-06-02 11:02 AM

I believe you can try putting them in .htaccess file. If you are encountering any issues after doing the same then try removing these entries and check if it is related (in case).

2007-06-02 11:50 AM

Regards,
Rahul

Hello Guest! In order to post you must be an active client with us, please log in or sign up today!