Simon Suh Simon Suh - 1 year ago 67
Apache Configuration Question

Why won't apache start again when I add a new nameserver in httpd-vhosts.conf file?

I am trying to change my localhost nameservers and I have added the following code to the C:\Windows\System32\drivers\etc\hosts file

and I have added the following code to the C:\xampp\apacheconf\extra\httpd-vhosts.conf file

<VirtualHost *:80>
DocumentRoot c:/xampp/htdocs/sites/directory
</VirtualHost *:80>

When I add the bit however and try to restart Apache in Xampp, it won't restart, and I'm assuming it's something to do with the port being blocked. How do I solve this so that Apache starts again?

Answer Source

Bingo that broke it when I used...

</VirtualHost *:80>

So just end your virtual hosts with the tag...

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download