I have a Joomla 2.5 based site where I am trying to redirect URLs containing /RK=0/RS= with random code at the end. They cause 404 errors in the server access log. Here are some examples:
/blog/name-of-blog-post.html/RK=0/RS=_ep9ZOcaWbdT5g4pr_m9ddy3Rxo-
I found several solutions that do not work for me:
RewriteEngine On RewriteRule ^(.*)/RK=0/RS= /$1 [L,NC,R=301] RewriteRule ^/blog/(.*)/RK=0/RS= /$1 [L,NC,R=301] RewriteRule ^/blog/(.*)(.html)/RK=0/RS= /$1 [L,NC,R=301] RewriteRule ^/blog/(.*)(.html)/RK=0/RS=(.*) /$1 [L,NC,R=301] RewriteRule ^(.*)RK=0/RS= /$1 [L,NC,R=301] RewriteRule ^(.*)RS=^ /$1 [L,NC,R=301] RewriteRule ^(.*)RK= /$1 [L,NC,R=301] RewriteRule ^(.*)/RK= /$1 [L,NC,R=301]
Any ideas on how to encode the rewrite to catch and delete /RK=0/RS=_ep9ZOcaWbdT5g4pr_m9ddy3Rxo- in the above example? I have hundreds of them with different random codes at the end of the urls.
apache .htaccess mod-rewrite rewrite
rholzler
source share