Need Help with .htaccess redirect one url to another with code
ok here is the problem I have a site directory that I am redirecting to another site
example old site
/olddir/viewvideo?id=gPOfurmrjxo
I need it to redirect to the new site/directory exactly the same
newsite .com/newdir/viewvideo?id=gPOfurmrjxo
I am using the following .htaccess code
RewriteEngine On
RewriteRule ^([a-z]+) newsite .com/newdir/ [R,NC,L]
it iis redirecting the folder traffic to the new site only it redirects it like so
newsite .com/newdir/?id=gPOfurmrjxo
which cause's errors since it is missing the "viewvideo" in the url
should redirect like this
newsite .com/newdir/viewvideo?id=gPOfurmrjxo
but for some reason everything before the ? is deleted there are other quieres like
newsite .com/newdir/index?id=gPOfurmrjxo
newsite .com/newdir/search?id=gPOfurmrjxo
but the same thing when it is redirected it send directly to
newsite .com/newdir/?id=gPOfurmrjxo
without the viewvideo or index or search ect.
what can I do to the .htaccess to recognize the words before the ? and carry it over exactly the same to the new domain or directory
Learn Video Marketing
AdWork Media » Global Affiliate Network & Content Locking Solutions
Custom Platform, Flexible Lockers, Offers For Every Country