Forum Moderators: phranque

Message Too Old, No Replies

Problem in 301 Redirection

Problem in 301 Redirection

         

gunjanp

11:26 am on Jul 23, 2008 (gmt 0)

10+ Year Member



Hallo,

I have given 301 redirection to my one page using this code in .htaccess

RewriteCond %{REQUEST_URI} ^/abcd.html?a_aid=moreinfo&a_bid=2c7f6314$
RewriteRule chantix.html?a_aid=moreinfo&a_bid=2c7f6314 /abcd.html [R=301]

and this code.

Redirect 301 /chantix.html?a_aid=moreinfo&a_bid=2c7f6314 /chantix.html

But both are not working. Anybody can suggest me how i can give 301 redirection using .htaccess

My all pages are in php and i have created it in .html through .htaccess.

Thanks in Advance

nick279

11:56 am on Jul 23, 2008 (gmt 0)

10+ Year Member



REQUEST_URI does not include query string as far as I know, need to capture that seperatley.

g1smd

12:39 pm on Jul 23, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month




You'll need to look at either QUERY_STRING or THE_REQUEST as well.