On 11/30/05, Rob Benton <[EMAIL PROTECTED]> wrote:
> I've got a site on my intranet running with mod_ssl.  This site used to
> run over plain http://.  I'd like to redirect everyone trying to access
> the old address to the new address via https://.
>
> I tried just:
> Redirect permanent http://site https://site
>
> but I get a 400 Bad Request error.  I also looked at mod_rewrite but
> wasn't sure if it would work for this.  What is the
> simplest/best/easiest way to do this?

I use:
        RewriteEngine on
        RewriteCond %{HTTP_HOST} !^xwis.net [NC]
        RewriteRule ^/(.*)       http://xwis.net/$1 [l,r=permanent]

You would not use the Cond and use https in the Rule.

Reply via email to