This forum has been moved here:
Helicon Tech Community Forum

  Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
ISAPI_Rewrite 2.x (Forum Locked Forum Locked)
 Helicon Tech : ISAPI_Rewrite 2.x
Subject Topic: Ignoring localhost rewrite condition?
Author
Message |
tximagineer
Newbie


Joined: 26 April 2011
Location: United States
Posts: 1
Posted: 26 April 2011 at 12:16pm

Please excuse my ignorance =)

Rewrite conditions are additive right?

Ala

RewriteCond %HTTPS (?!on).*
RewriteCond Host: (.*)
RewriteRule (.*) https\://$1$2 [I,RP]

...

If it passes condition 1+2, enable rule 3.

I'm trying to rewrite everything EXCEPT queries coming
from localhost to https. Can anyone help me out here? I
tried adding

RewriteCond From: (?!127.0.0.1)

Similarly I said "okay.. well how about if I just ignore
writes TO localhost?

RewriteCond Host: (?!localhost)

Didn't work either. :|

Any help would be appreciated.

Back to Top Visit tximagineer's Homepage
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 27 April 2011 at 4:12am

The rules should be:

RewriteCond %HTTPS (?!on).*
RewriteCond Host: (?!localhost)(.*)
RewriteRule (.*) https\://$1$2 [I,RP]

__________________
Regards,
Anton
Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum