Cache-Control in phpbb

Discussions about the phpBB3 Forum. How to get the best from this powerful script.
Note that there is no official support for phpBB3 here, a place to share more than to ask for.

Moderator: Moderators

Cache-Control in phpbb

Postby yaashul » Mon Aug 15, 2011 2:28 pm

I was looking at phpbb-seo header and couldn't understand the meaning of those 2 lines

Cache-Control: private, no-cache="set-cookie"
Pragma: no-cache

What is the purpose of those and how can I set these for my forum?
yaashul
PR1
PR1
 
Posts: 160
Joined: Wed Aug 29, 2007 1:21 am

Advertisement

Re: Cache-Control in phpbb

Postby yaashul » Tue Aug 16, 2011 8:02 pm

I did set the following thing in .htaccess
Code: Select all
      # 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)$">
      ExpiresDefault A29030400
      Header append Cache-Control "public"
      </FilesMatch>
      
      # Set up caching on media files for 1 week
      <FilesMatch "\.(gif|jpg|jpeg|png|swf)$">
      ExpiresDefault A604800
      Header append Cache-Control "public"
      </FilesMatch>
      
      # Set up 2 Hour caching on commonly updated files
      <FilesMatch "\.(xml|txt|html|js|css)$">
      ExpiresDefault A7200
      Header append Cache-Control "proxy-revalidate"
      </FilesMatch>
      
      # Force no caching for dynamic files
      <FilesMatch "\.(php|cgi|pl|htm)$">
      ExpiresActive Off
      Header set Cache-Control "private, no-cache, no-store, proxy-revalidate, no-transform"
      Header set Pragma "no-cache"
      </FilesMatch>


Everything seems fine except style.php?id=1&amp;lang=en reloading everytime I open any page on forum...

I checked the header and it says expire = 0 how can I set proper header and expire value? Please suggest...
yaashul
PR1
PR1
 
Posts: 160
Joined: Wed Aug 29, 2007 1:21 am

Re: Cache-Control in phpbb

Postby yaashul » Thu Aug 25, 2011 12:55 pm

Please anyone suggest me something...
yaashul
PR1
PR1
 
Posts: 160
Joined: Wed Aug 29, 2007 1:21 am


Return to phpBB Forum

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: Google Adsense [Bot] and 10 guests