If you want a Domain Alias to redirect and put the correct hostname in
the URL bar of the browser, you can use mod_rewrite. If you are hosting
original.com and have a domain alias of alias.com and you want all
requests for alias.com urls to be redirected back to original.com urls,
then you would put this in an .htaccess file in any directory where you
want this redirection to happen:
Code:
RewriteEngine on
RewriteCond %{HTTP_HOST} alias.com$ [NC]
RewriteRule ^(.*)$ http://www.original.com/$1 [R]
The rule will affect all directories below the one where you put this
.htaccess file. So a request for
http://www.alias.com/docs/services.html
will be redirected to
http://www.original.com/docs/services.html as
well.