Forum Moderators: phranque
I have tried the following on my server and it does nothing.
RedirectMatch permanent ^/script.php?this=(.*) http:*/www.me.com/s/script2.php?foo=xxxx&that=(.*)
The variables "this" and "that" are the same variable but with a different name. The variable "foo" is fixed and is manualy inserted.
In my code http:*/ was simply used to prevent a link.
Any ideas why this wont work :)
Mack.
It might be worth typing a totally fresh copy of that line in case there's a stray invisible character hiding in there that you're not aware of.
Check this out:
[webmasterworld.com ]
Try something like this:
RewriteCond %{QUERY_STRING} ^this=(.*)$
RewriteRule ^script\.php$ http:*/www.me.com/s/script2.php?foo=xxxx&that=%1 [R=301,L]
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{QUERY_STRING} ^this=(.*)$
RewriteRule ^script\.php$ http:*/www.me.com/s/script2.php?foo=xxxx&that=%1 [R=301,L]
Ref: Introduction to mod_rewrite [webmasterworld.com]
Jim