Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the '10.5: Use Apache virtual hosts outside the Sites folder' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.5: Use Apache virtual hosts outside the Sites folder
Authored by: enthooz on Jun 11, '09 09:39:20PM

Virtual hosts are a method of serving multiple sites without the need to change directory names, especially when using name based virtual hosting. So one could easily have multiple directories inside the ~/Sites folder and point individual virtual hosts at each of these sites. By updating /etc/hosts or /private/etc/hosts, your system can be configured so that typing 'apple' or 'baboon' or whatever name you choose points to different vhosts (sites) on your machine. I was just looking for a way to get out of being confined to keeping the sites I'm serving in either /Library/WebServer or /Users/*/Sites. In OS X, it seems like the best option is keeping web projects in Sites and using symlinks to easily access them from elsewhere. I suggest looking into name based virtual hosts to avoid the hassle of renaming folders.

[ Reply to This | # ]