- Code: Select all
#
# Virtual Hosts
#
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs/2.2/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.
#
# Use name-based virtual hosting.
#
NameVirtualHost *:80
<VirtualHost *:80>
DocumentRoot "C:/xampp/htdocs/"
ServerName loclahost
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "C:/xampp/htdocs/xampp/"
ServerName xampp.loclahost
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "C:/xampp/htdocs/enb/"
ServerName enb.loclahost
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "C:/xampp/htdocs/test/"
ServerName test.loclahost
</VirtualHost>
This wont work for some reason all of my hosts are pointing to the localhost folder "C:/xampp/htdocs" can any one help - i have tryed adding the <Directory path> for each