**Resolved** Apache virtual Server problem
I want to have to addresses
mydomain.com (www.mydomain.com) that points to /var/www/html/mydomain
and
webmail.mydomain.com that points to /var/www/html/webmail
I have one IP so I am using name based
I tried this:
<VirtualHost *:80>
ServerName webmail.mydomain.com
DirectoryIndex index.php
DocumentRoot /var/www/html/webmail
</VirtualHost>
<VirtualHost *:80>
ServerName mydomain.com
ServerAlias www.mydomain.com
DirectoryIndex index.php
DocumentRoot /var/www/html/mydomain
</VirtualHost>
The first part work I can view my webmail but when I browse to mydomain.com or www.mydomain.com it goes to the webmail folder instead of the mydomain folder.
Please Help