Add expires.

Add Expires headers to page.

Where to place and code.

Using C5 6.3

View Replies:
buurvrouw replied on at Permalink Reply
Create a file .htaccess in the root of your site and put this code in it:

<IfModule mod_expires.c>
   <IfModule mod_headers.c>
      Header unset Pragma
      FileETag None
      Header unset ETag
      # Turn on Expires and set default to 0
      ExpiresActive On
      ExpiresDefault A0
      # Set up caching on media files for 1 year (forever?)
      <FilesMatch "\.(flv|ico|pdf|avi|mov|ppt|doc|mp3|wmv|wav|gif|jpg|jpeg|png|swf|svg|woff)$">
         ExpiresDefault A29030400
         Header append Cache-Control "public"
      # Set up 31 days caching on commonly updated files
      <FilesMatch "\.(xml|txt|html|js|css|php)$">
grannyiescrazy replied on at Permalink Reply
Have code in hataccess file.

Need help with:Leverage browser caching
Setting an expiry date or a maximum age in the HTTP headers for static resources instructs the browser to load previously downloaded resources from local disk rather than over the network.
Leverage browser caching for the following cacheable resources: (15 minutes) in a block. (2 hours) tracking code.