"Start by creating a directory where all your working
copies will live. For this article I will assume that this is
/home/checkout. Every directory under this directory will become a
subdomain on your development server. Create a trunk directory
under the checkouts directory (/home/checkout/trunk). This is where
the main dev.example.org domain will go to. When a subdomain does
cannot resolve to a directory under /home/checkouts we want to show
an error page. I created /home/checkouts/error.html containing some
useful information, but you could also redirect it to a 404 error
if you want."