Hi, I would like to redirect all my requests, http://*.example.com to http://www.example.com/* So something like http://subdomain.example.com would become http://www.example.com/subdomain/ Does anybody know where I could find a tutorial to achieve this? Many thanks FFMG
Create a .htaccess file containing the following lines: RewriteEngine on RewriteCond %{HTTP_HOST} ^example\.com [NC] RewriteRule (.*) http://www.example.com/$1 [L,R=301] RewriteCond %{HTTP_HOST} !^(www\.)?example\.com [NC] RewriteCond %{HTTP_HOST} ^(.*)\.example\.com RewriteRule ^(.*)$ http://example.com/%1/$1 [L,NC,QSA] Code (markup): Don't forget to change 'example.com' with your actual domain name.