I've been using Xampp on Windows for some time now. I'm trying to set it up on Mac OS X also, so I copied all the configuration, but I can't get virtual hosts to work.
1- I included this in /private/etc/hosts:
2- I included this in httpd.conf:
3- I included this in httpd-vhosts.conf:
Which is basically the same configuration I have on Windows. The result I get on MacOS is that any domain defined in the hosts file gets you to httpd.conf's DocumentRoot, I.E. /Volumes/Files/http and not to the virtual host's root. Any ideas?
New tags: apache-vitual-hosts vhosts vhosts.conf virtual-hosts
Thanks for all the answers. I've tried to work it out, moved the line Include etc/extra/httpd-vhosts.conf to another place in httpd.conf ( don't ask why ) and it worked. But the problem now seems to be that the only virtual host that is recognized is the first that's defined.
All the domains defined on /etc/hosts point now to that virtual host. If I comment it out in httpd-vhosts.conf and restart apache, then all domains point to the second one.
It seems that declaring all is the problem? ( but it's not on windows )
I tried * and didn't work. I'll try *:80 and see what happens. Thanks!