The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Htaccess :: HTTPS to HTTP :: Redirect Entire Site ?, .htaccess 301 redirect HTTPS to HTTP
scott g
post May 16 2012, 01:29 PM
Post #1


Member
***

Group: Members
Posts: 32
Joined: 8-November 10
From: StL, MO
Member No.: 13,098



I've been doing searches for the answer to this question and I keep finding the answer.. To redirect only a portion of a site... Not what I want. I want to redirect the ENTIRE website!

If (for some reason) the user starts out with HTTPS and types in the rest of my websites URL I get a "Secure Connection Fail" or another error.

Ex. https://lawsuitinformation.org --->
automatically redirect to http://lawsuitinformation.org
((Secure Connection Failed - An error occurred during a connection to lawsuitinformation.org. (Error code: ssl_error_rx_record_too_long)))

Ex. https://www.careydanis.com ---> automatically redirect to http://www.careydanis.com
((Unable to connect - Firefox can't establish a connection to the server at www.careydanis.com.))

Can anyone help me out here?!

CODE
RewriteCond %{HTTPS} on
RewriteCond %{REQUEST_URI} !^(/checkout)
RewriteRule ^(.*)$ http://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]


NO "(/checkout)" ---> WHOLE site/domain!

Anyone... Anyone...? Everytime I get stuck with something stupid someone on this forum knocks my simple problem out of park! So THANK YOU in advance tongue.gif


--------------------
Scott G.
"Whatever the mind can conceive and believe, the mind can achieve."

*avandia lawsuit paxil birth defects lawsuit zoloft birth defects lawsuit lexapro birth defects lawsuit
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post May 16 2012, 04:54 PM
Post #2


WDG Member
********

Group: Root Admin
Posts: 7,851
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



If you're using Apache, then the "Resource Moved to Another Server" example here may help:
http://httpd.apache.org/docs/2.4/rewrite/r...ml#movehomedirs


--------------------
Darin McGrew
WDG Member since 1998
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
2 User(s) are reading this topic (2 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 19th May 2013 - 07:31 AM