This problem has never occurred in the past (i have tried this many times) but this time,
ALL virtual hosts defined in the virtual-hosts.conf file in the apache installation directory direct the browser to the apache server documentRoot directory.
I am using windows 7 with the latest version of apache.
These are the virtual hosts defined
NameVirtualHost *:80
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for all requests that do not
# match a ServerName or ServerAlias in any <VirtualHost> block.
#
<VirtualHost *:80>
ServerName dev.a.local
ServerAlias dev.a.local
DocumentRoot "D:/wwwroot/a/public"
ErrorLog "logs/a.log"
CustomLog "logs/a-access.log" common
<Directory "D:/wwwroot/a/public">
Options Indexes FollowSymLinks
AllowOverride All
# Controls who can get stuff from this server.
Order allow,deny
Allow from all
DirectoryIndex index.php
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerName dev.b.local
ServerAlias dev.b.local
DocumentRoot "D:/wwwroot/b/public"
ErrorLog "logs/b.log"
CustomLog "logs/b-access.log" common
<Directory "D:/wwwroot/b/public"s>
Options Indexes FollowSymLinks
AllowOverride All
# Controls who can get stuff from this server.
Order allow,deny
Allow from all
DirectoryIndex index.php
</Directory>
</VirtualHost>
I have modified the hosts file and added
127.0.0.1 dev.a.local
127.0.0.1 dev.b.local
When i try to access dev.a.local or dev.b.local i am directed to the documentRoot of apache defined in httpd.conf.
Please help.