I am trying to access: http://www.domain.mobi/aff_admin with a subdomain something like that: http://aff_admin.domain.mobi
but for some reason I'm unable to make it work. I was trying this following code:
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^(www\.)?domain\.mobi
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ([a-z0-9-]+)/? http://$1.domain.mobi [R=301,NC,L]
Any Idea why its not working? Im running my website on a Amazon server.