NameVirtualHost *:80
<VirtualHost *:80>
DocumentRoot /var/www/html/domaina/
ServerName www.domaina.com
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTP_HOST} ^domaina\.com$ [NC]
RewriteRule ^(.*)$ http://www.domaina.com$1
[R=301,L]
</VirtualHost>
<VirtualHost *:80>
DocumentRoot /var/www/html/domainb/
ServerName www.domainb.com
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTP_HOST} ^domainb\.com$ [NC]
RewriteRule ^(.*)$ http://www.domainb.com$1
[R=301,L]
</VirtualHost>
However all requests to http://domainb.com/ gets
redirected to http://www.domaina.com whereas the
expected behaviour is to get redirected to
http://www.domainb.com/ .
Regards
Deepan
Photographic Memory Game:
http://www.photographicmemorygame.com/
Sudoku Solver: http://www.sudoku-solver.net/