views:

21

answers:

1

I have the following:

RewriteEngine On

# Check if the host name contains a . (localhost won't)
# Check if the host name starts with www
# Check if the host name ends with .com
# Check if the connection is secure
RewriteCond %{HTTP_HOST}  \.
RewriteCond %{HTTP_HOST} !^www   [OR]
RwriteCond  %{HTTP_HOST} !\.com$ [OR]
RewriteCond %{HTTPS}     !=on
RewriteRule ^.*$ https://www.myDomain.com/$0 [R=301,L]

I want to EXCLUDE these checks for svn.mydomain.com (i.e. so svn.mydomain.com does NOT redirect AT ALL. How do I do that?

+1  A: 

One easy way would be to add

RewriteCond %{HTTP_HOST} !svn.mydomain.com

before your existing conditions.

David Zaslavsky