LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > LiteSpeed Cache > IPB .htaccess Furls and Litespeed Cache

Reply
 
Thread Tools Display Modes
  #1  
Old 10-28-2011, 07:35 AM
vamman vamman is offline
New Member
 
Join Date: Oct 2011
Posts: 2
Exclamation IPB .htaccess Furls and Litespeed Cache

Hey folks,

I followed this tutorial to the letter for our IPB Board.
http://litespeedtech.com/support/wik...:cache:ipboard

This is a big board and we thought we had the .htaccess fine tuned for the forums but it appears not. Seemed when we setup the IPB SE Friendly URLs .htaccess rule with the litespeed .htaccess rule and some visitors started reciecing infinite redirect notices using mobiles and google translator. Upon inspection it appears we failed at the rule rewrite mod for IPB and LS Cache.

Please help me with this if you can:

Litespeed rule:
RewriteEngine On
###########################################
# For LiteSpeed public cache (guest user)
###########################################
RewriteCond %{REQUEST_METHOD} ^HEAD|GET$
RewriteCond %{HTTP_COOKIE} !member_id= [OR]
RewriteCond %{HTTP_COOKIE} member_id=0
RewriteCond %{REQUEST_URI} !^/admin
RewriteCond %{REQUEST_URI} !(css|js|png|gif)$
RewriteCond %{QUERY_STRING} ^$
RewriteRule .* – [E=Cache-Control:max-age=360]

IPB SEO Rule:
Options -MultiViews
RewriteEngine On
RewriteBase /forums/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /forums/index.php [L]
Reply With Quote
  #2  
Old 10-28-2011, 10:09 AM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,337
You may try the following rules:
%
Quote:
Options -MultiViews
RewriteEngine On
RewriteBase /forums/
###########################################
# For LiteSpeed public cache (guest user)
###########################################
RewriteCond %{REQUEST_METHOD} ^HEAD|GET$
RewriteCond %{HTTP_COOKIE} !member_id= [OR]
RewriteCond %{HTTP_COOKIE} member_id=0
RewriteCond %{REQUEST_URI} !^/forums/admin
RewriteCond %{REQUEST_URI} !(css|js|png|gif)$
#RewriteCond %{QUERY_STRING} ^$
RewriteRule .* – [E=Cache-Control:max-age=360]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /forums/index.php [L]
Make sure to put non-cacheable URLs in Do-Not-Cache box.

Also enable rewrite logging to troubleshoot.
Reply With Quote
  #3  
Old 10-28-2011, 10:22 AM
vamman vamman is offline
New Member
 
Join Date: Oct 2011
Posts: 2
Thanks. Sorry the same issue occurs. This looks like what I had before.

Are you suppose to have multiple rewrites? I thought you could combine the rewrite together?
Reply With Quote
  #4  
Old 10-28-2011, 10:57 AM
webizen webizen is offline
LiteSpeed Staff
 
Join Date: Oct 2010
Posts: 2,337
Yes, you can have multiple rewrites. Usually LS cache rules should be put in front of other rules (that's why no 'L' for the '.* -' one). Please enable rewrite logging to troubleshoot.
Reply With Quote
  #5  
Old 10-28-2011, 11:24 AM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,585
Quote:
Originally Posted by vamman View Post
Thanks. Sorry the same issue occurs. This looks like what I had before.
I think you need to find out which URL is causing the trouble.
Maybe something should not be cached has been cached. and turn cache off for that URL.
If you can reproduce the problem, you can check it with firebug, or use tcpdump to dump the request/response related at network level.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 08:50 AM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.