Forum Moderators: phranque
I am attempting to redirect all traffic to use a particular hostname and SSL. There are multiple DNS entries for the server:
example.org
example.com
I want to redirect all http and https traffic on all DNS entries to be redirected to https on example.com.
I have the following entry in my httpd.conf file:
RewriteEngine on
RewriteRule ^/(.*)$ [example.com...]
If someone hits
http://example.com
http://example.org
[example.com...] (obviously)
the desired redirect behaviour is achieved.
If someone enters [example.org,...] the server performs no redirection. The user is able to view the web content, but retains the original URL.