I need to redirect all the traffic from
http://subdomain.domain.com/
to
http://subdomain.domain.com/folder/
With 'folder' being a specific folder, of course. I've tried this:
RewriteCond %{HTTP_HOST} ^subdomain\.domain\.com$
RewriteRule ^.*$ http://subdomain.domain.com/folder/ [L]
But it doesn't work. What's wrong?
Try this:
The only change I made was to add
R
in the options after the RewriteRule. That option tells Apache to do a 302 redirect. You can useR=301
if you want a permanent redirect.