Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

zigdon's scratchpad

by zigdon (Deacon)
on Jun 03, 2004 at 20:38 UTC ( [id://360480] : scratchpad . print w/replies, xml ) Need Help??

RewriteEngine on RewriteCond %{HTTP_HOST} !^www\.site\.com$ RewriteCond %{HTTP_HOST} !^site\.com$ RewriteRule ^(.+) %{HTTP_HOST}$1 [C] RewriteRule ^([^.]+)\.site\.com(.*) /path/to/docroot/$1/$2