apache - htaccess redirect subdomain to subfolder of another domain -
i'm using .htaccess proxy redirect content of subdomain subfolder of domain as: www.domain1.com/support show content site1-support.domain2.com
while keeping address bar showing hxxp://www.domain1.com/support.
to this, i've created empty folder called "support" under www.domain1.com , add .htaccess:
<ifmodule mod_rewrite.c> rewriteengine on rewriterule ^/?support/(.*)$ http://site1-support.domain1.com/$1?proxy=http://site1-support.domain2.com [p] </ifmodule>
this works, whenever there ? in url doesn't show page, such hxxp://www.domain1.com/kb.php?article=1
any htaccess gurus out there?
if want forward article=1
redirectrule
should add qsa flag.
rewriterule ^/?support/(.*)$ http://site1-support.domain1.com/$1?proxy=http://site1-support.domain2.com [qsa,p]
hope helps, , understood question correctly. :)
Comments
Post a Comment