I went through lots of SO questions but non is giving me the right answer .
I have following config in apache vhost:
<VirtualHost *:80>
DocumentRoot "D:/Web Server/xampp/htdocs/testsite/frontend/www"
ServerName mydomain.com
ServerAlias www.mydomain.com
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "D:/Web Server/xampp/htdocs/testsite/backend/www"
ServerName admin.mydomain.com
ServerAlias www.admin.mydomain.com
</VirtualHost>
AND hosts file :
127.0.0.1 testsite.com
127.0.0.1 admin.testsite.com
What I need is that:
www.testsite.com and testsite.com should point to same thing
and same with
www.admin.testsite.com and admin.testsite.com
What is the issue with this config ? Do I need to add separate records for each , one with www and other without www ?
please help me sort this issue
thanks in advance