Map a local domain using apache httpd.conf and windows hosts file

Posted by & filed under Windows webserver.

Add a host file definition, eg:

This tells your PC to send that domain to localhost. Now in apache’s httpd.conf you set up a virtual host to map that domain on localhost to a ‘DocumentRoot’ directory on your machine:

DocumentRoot "C:\xampp\htdocs\mydomain"

Leave a Reply

  • (will not be published)

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>