/ Published in: Other
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
# Mass Virtual Hosting (mod_rewrite method) <VirtualHost 127.0.0.1> ServerAlias *.dev RewriteEngine on RewriteCond %{HTTP_HOST} ^(.+).dev RewriteCond /Users/username/Sites/dev/%1/httpdocs -d RewriteRule ^(.*) /Users/username/Sites/dev/%1/httpdocs/$1 [L] <Directory /Users/username/Sites/dev/*/httpdocs> AllowOverride All </Directory> </VirtualHost> <VirtualHost *:80> ServerAlias *.somecustom.dyndns.org RewriteEngine on RewriteCond %{HTTP_HOST} ^(.+).somecustom.dyndns.org RewriteCond /Users/username/Sites/dev/%1/httpdocs -d RewriteRule ^(.*) /Users/username/Sites/dev/%1/httpdocs/$1 [L] <Directory /Users/username/Sites/dev/*/httpdocs> AllowOverride All </Directory> </VirtualHost>