Forum Moderators: travelin cat
NameVirtualHost 127.0.0.1
<VirtualHost 127.0.0.1>
ServerName 127.0.0.1
DocumentRoot /Users/pamelaparks/Sites
</VirtualHost>
<VirtualHost test.officeApp.com>
ServerName test.officeApp.com
DocumentRoot /Users/pamelaparks/Sites/officeApp/
</VirtualHost>
<VirtualHost test.Baker.com>
ServerName test.Baker.com
DocumentRoot /Users/pamelaparks/Documents/WebDesignPam/MySites/Baker_folder/Baker
</VirtualHost>
127.0.0.1 localhost
127.0.0.1 test.officeapp.com
127.0.0.1 test.Baker.com
255.255.255.255 broadcasthost
::1 localhost
<VirtualHost 127.0.0.1>
ServerName 127.0.0.1
DocumentRoot /Users/pamelaparks/Sites
</VirtualHost>
If your are hooked up to a router, you could try using the ip that it gives your Mac and make the changes in httpd.conf and hosts. Thats the way I did it and it worked for me.
Try this instead:
NameVirtualHost *
<VirtualHost *>
</VirtualHost>
<VirtualHost *>
ServerAdmin mozilla@mathiesen.info
ServerName test.mozilla.info
DocumentRoot "/Volumes/brugere/bjarnema/Mozilla/Documents"
<Directory "/Volumes/brugere/bjarnema/Mozilla/Documents">
Options Indexes
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
The first empty VirtualHost will default to the way the server has been configured in the main body of the httpd.conf file.
The following URL should give you the manual entry for <VirtualHost>
[localhost...]
at least with Apache 2.0.x - might be different if you are using Apache 1.3.x
If yoo do a 'lookupd -configuration' you'll find the following lines:
LookupOrder: Cache FF DNS NI DS
_config_name: Host Configuration