Assigning a local domain to a project

I’m currently using Apache’s mod_userdir on OS X Snow Leopard so I’m accessing the localhost like this: http://localhost/~myusername/ProjectName.

What I need to accomplish is accessing ProjectName via http://projectname.loc.

I tried the following with no success:

Added this like to /etc/hosts: projectname.loc
Created a VirtualHost in /private/etc/apache2/extra/httpd-vhosts.conf like this:
    <VirtualHost *:80>
    ServerName projectname.loc
    DocumentRoot /Users/myusername/Sites/ProjectName

What I’m missing?

Your help would be greatly appreciated.

It should be, not :slight_smile:

Thanks :slight_smile: