.htaccess - Subdomain to folder htaccess -


I'm trying to point to sub.domain.com on domain.app / domain_app / * sub, but most I can get away from it, it is making a redirection and I do not want to redirection it. Here's what I have, it works but instead of being on the subdomain it redirects, which I want.

Revoked% {HTTP_HOST} ^ (. *). Example.com revoked code% {HTTP_HOST}! ^ Www.example.com [nc] rewriteable ^ (. *) $ Http: // Example.com/app/%1/$1 [L]

You must either redirect or force proxy behavior Also see and use the flag flag to use the mod_rewrite for the proxy:

  rewrite% {HTTP_HOST} ^ (. *). Example.com RewriteCond% {HTTP_HOST}! ^ Www.example.com [NC] revised rule ^ (. *) $ Http://example.com/app/%1/$1 [P]  

You can instead / app You can rewrite $ 1 / $ 1 for $ 1, but then subdomain's virtualhost configuration will not be applicable.


Comments