Forum Moderators: phranque

Message Too Old, No Replies

Redirect Problem to Dynamic Webpage URL in .htaccess file

About redirect problem to dynamic webpage URL in .htaccess file.

         

revivalfire

6:15 pm on Mar 10, 2006 (gmt 0)



I want to permanently redirect an html page to a dynamic url residing on another server. Problem is that it changed the "?" in the url to %3f

here was my code in htaccess...

RedirectMatch permanent ^/Medishare.html$
http://www.example.org/landing/?ref=eld0007-em0001

when redirected it goes to this url...
http://www.example.org/landing/%3fref=eld0007-em0001

For some reason it is changing? to %3f. What do I do to change this to make it resolve correctly?

[edited by: jdMorgan at 9:44 pm (utc) on Mar. 10, 2006]
[edit reason] Exaplified URl, Please see TOS. [/edit]

jdMorgan

9:48 pm on Mar 10, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



%3f is the %-encoded value for a question mark.

mod_alias is an older module, and doesn't handle query strings well. You might want to try mod_rewrite instead.


Options +FollowSymLinks
RewriteEngine on
RewriteRule ^Medishare\.html$ http://www.example.org/landing/?ref=eld0007-em0001 [R=301,L]

Jim