...

View Full Version : Rewrite from https to http? HELP!



martinos
03-16-2010, 08:12 PM
Hello

I have met a problem with the rewrite of my .Htaccess.

Now i have my entire site to be rewrite'ed from http://www.mysite.com to https://secure.mysite.com
and it's encoded in my .htaccess:

[code] Options +FollowSymlinks
RewriteEngine on
RewriteCond %{HTTP_HOST} !^secure.mysite.com [NC]
RewriteRule ^(.*)$ https://secure.mysite.com/$1 [L,R=301] [/ code]

In this way, every single page redirected to my secure server at https://secure.mysite.com
It works very well and so it shall remain.


but there is a single page, which I do not want to become rewrite'ed,
eg I do not want to http://www.mysite.com/page1.php be rewriteed to https://secure.mysite.com/page1.php
it is the only urI do not want it to rewrite,

what should I add more to the code I have currently?

I hope you could help .. :)
ps. I am not an expert so I may like to write what to add to my code: wink:

Sincerely, Martin

angst
03-18-2010, 01:59 PM
something like this should do;



RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteCond %{REQUEST_URI} somefile.php
RewriteRule ^(.*)$ https://www.domain.com/somefile.php [R,L]



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum