Reputation: 1061
I have a url something like
www.mydomain.com/mydomain
but when someone types as www.mydomain.com the above should load without url redirection. How can I achieve this?
Thanks in advance.
Upvotes: 0
Views: 47
Reputation: 11
RewriteEngine on
RewriteCond %{HTTP_HOST} ^subdomain\.yourdomain\.com
RewriteRule ^(.*)$ subdomain/$1 [L,QSA]
Also see : Apache mod_rewrite - rewriting from subdomain to main domain
Upvotes: 1