Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Conditional rewrite HTTPS to HTTP

Status
Not open for further replies.

cp2000

Technical User
Dec 31, 2002
81
0
0
US
I have a domain that is running both http and https. It is runnig as a virtual host under Apache 1.3.27. There are certain applications (by virtue of directories) that are non functional under https. Therefore I need to conditionally rewrite https to http.

To start with - index.html

The mod_rewrite rule, in my vhost conf file is:
Code:
   <IfModule mod_rewrite.c>
      RewriteLog "/usr/local/apache/logs/domain/rewrite_log"
       RewriteLogLevel 7
       RewriteEngine On
       #RewriteRule ^/index.html/(.*) [URL unfurl="true"]http://domain.com/index.html$1[/URL] [R]
       RewriteRule ^/(.*)$ [URL unfurl="true"]http://domain.com/index.html[/URL] [R]
    </IfModule>

I read in one of the other post here about using META tags but that didn't seem to work either. It looks like using rewrite is the way to go. I just can't get the syntax.....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top