Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-09 Thread Michael Menegakis
On Tue, Mar 9, 2010 at 11:01 AM, Philip Wigg wrote: > On 9 March 2010 07:57, Michael Menegakis wrote: >> On Mon, Mar 8, 2010 at 11:12 AM, Philip Wigg wrote: >>> On 8 March 2010 05:17, Michael Menegakis wrote: Hi all A rule is in place that that rewrites domains to www.domains >>>

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-09 Thread Philip Wigg
> It goes into an infinite loop again. I believe the root is forcing a > rule by 'inherit'. If I understand you correctly, you don't have access to the main httpd configuration file. If there's a rewrite in that file which is redirecting your site from domain.com to www.domain.com then I can't thi

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-09 Thread Philip Wigg
On 9 March 2010 07:57, Michael Menegakis wrote: > On Mon, Mar 8, 2010 at 11:12 AM, Philip Wigg wrote: >> On 8 March 2010 05:17, Michael Menegakis wrote: >>> Hi all >>> >>> A rule is in place that that rewrites domains to www.domains >>> >>> In one particular home dir, I need the opposite, >>> >>

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-08 Thread Michael Menegakis
On Mon, Mar 8, 2010 at 11:12 AM, Philip Wigg wrote: > On 8 March 2010 05:17, Michael Menegakis wrote: >> Hi all >> >> A rule is in place that that rewrites domains to www.domains >> >> In one particular home dir, I need the opposite, >> >> RewriteEngine On >> RewriteCond %{HTTP_HOST} ^www.domain.

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-08 Thread Nilesh Govindarajan
On Mon, Mar 8, 2010 at 10:47 AM, Michael Menegakis wrote: > Hi all > > A rule is in place that that rewrites domains to www.domains > > In one particular home dir, I need the opposite, > > RewriteEngine On > RewriteCond %{HTTP_HOST} ^www.domain.com$ [NC] > RewriteRule ^(.*)$ http://domain.com/$1

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-08 Thread Michael Menegakis
On Mon, Mar 8, 2010 at 7:51 AM, Igor Cicimov wrote: > Try using the following to stop the endless loops: > > RewriteCond %{ENV:REDIRECT_STATUS} 200 > RewriteRule .* - [L] It doesn't stop looping if it's put before the rule, after the rule or even if it's both after and before the rule. -

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-08 Thread Philip Wigg
On 8 March 2010 05:17, Michael Menegakis wrote: > Hi all > > A rule is in place that that rewrites domains to www.domains > > In one particular home dir, I need the opposite, > > RewriteEngine On > RewriteCond %{HTTP_HOST} ^www.domain.com$ [NC] > RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L] >

Re: [us...@httpd] Avoid endless loop of mod_rewrite

2010-03-07 Thread Igor Cicimov
Try using the following to stop the endless loops: RewriteCond %{ENV:REDIRECT_STATUS} 200 RewriteRule .* - [L] Igor On Mon, Mar 8, 2010 at 4:17 PM, Michael Menegakis wrote: > Hi all > > A rule is in place that that rewrites domains to www.domains > > In one particular home dir, I need the oppo

[us...@httpd] Avoid endless loop of mod_rewrite

2010-03-07 Thread Michael Menegakis
Hi all A rule is in place that that rewrites domains to www.domains In one particular home dir, I need the opposite, RewriteEngine On RewriteCond %{HTTP_HOST} ^www.domain.com$ [NC] RewriteRule ^(.*)$ http://domain.com/$1 [R=301,L] But it goes into an endless loop that eventually makes firefox s