Jump to content

Setting up a DNS server


rick.emmet

Recommended Posts

Yeah, my windows host file is pretty packed with 127.0.0.1 / other IPs for development work.

 

C:\Windows\System32\drivers\etc\hosts

127.0.0.1	localhost

# Portfolio Dev Site
127.0.0.1   misterphilip.dev

# PHP Freaks Dev Site
127.0.0.1   phpfreaks.dev
127.0.0.1   forums.phpfreaks.dev

# etc..

Hi Everyone,

Thanks for the additional posts. I went ahead and attempted to configure the two files (even though I found a lot of variations in articles and such).

 

The first time I attempted to use the name of the site, I got the phpMyAdmin page. I looked at several different sites and they had a number of inconsistancies. I fiddled around with the code and got it working. In the "httpd-vhost.conf" file (located at C:\xampp\apache\conf\extra), I uncommented the following line of code:

 

NameVirtualHost *:80	

 

And added the lines of code below:

 

NameVirtualHost *
  <VirtualHost *:80>
    DocumentRoot "C:\xampp\htdocs"
    ServerName localhost
  </VirtualHost>
  <VirtualHost *>
    DocumentRoot "C:\xampp\htdocs\travelersfreeclassifieds"
    ServerName Travelersfreeclassifieds.local
  <Directory "C:\xampp\htdocs\travelersfreeclassifieds">
    Order allow,deny
    Allow from all
  </Directory>
</VirtualHost>

 

The write up I used originally had <VirtualHost* >. Some of the other sites had a number of differences, and I changed the line to: <VirtualHost *:80>. It makes sense that you would want the virtual host turned on & it makes sense to identify the port as well. Thanks again for the clarification, I thought that you would have multiple lines in the "host" file, but wasn't sure. I Hope this helps!

Cheers,

Rick

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.