.htaccess for rewriting https to http
Posted: Sun Dec 03, 2006 9:56 am
I don't have SSL installed but sometimes people try to access my site through https and the following error shows up. How can I redirect everyone from https://www.mysite.com to http://www.mysite.com ? I tried the following 2 codes but they don't work.
http://www.mysite.com has sent an incorrect or unexpected message. Error code: -12263
http://www.mysite.com has sent an incorrect or unexpected message. Error code: -12263
Code: Select all
RewriteCond %{SERVER_PORT} 443
RewriteRule (.*) http://www.mysite.com/$1 [R]Code: Select all
RewriteEngine on
RewriteCond %{HTTP_HOST} ^https://www.mysite.com [NC]
RewriteRule ^(.*)$ http://www.mysite.com/$1 [L,R=301]