The subject does not properly explain what my problem is. I had received some excellent help from Lucy a few months back in writing the following code
# Redirect to remove hex-encoded query string characters from DOGS folder
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /([^/]+/)*index\.php\%3[fF]folder\%3[dD]([^\ ]+)\ HTTP/
RewriteRule ^dogs/index\.php http://www.example.com/dogs/index.php?folder=%2 [R=301,L]
This is the link to the thread where we ended up with the code being created. [
webmasterworld.com...]
The purpose of this code (which is working) is to capture any reference in the form index.php%3Ffolder%3D and change it to index.php?folder=
This works for all references to the dogs folder. I then also wanted this to work for the CATS and BIRDS folders as well. I used the same format to create another similar RewriteCond as follows :-
# Redirect to remove hex-encoded query string characters from CATS folder
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /([^/]+/)*index\.php\%3[fF]folder\%3[dD]([^\ ]+)\ HTTP/
RewriteRule ^cats/index\.php http://www.example.com/cats/index.php?folder=%2 [R=301,L]
However, although the DOGS works, the CATS and BIRDS version does not? Within my HTACCESS the DOGS rerwite came first so I decided to swap the CATS rewrite to before the DOGS rewrite to see if that made a difference but it did not.
I also experimented with this code which I though should work and also simplify the amount of code, but this also did not work except for DOGS :-
# Redirect to remove hex-encoded query string characters from DOGS, CATS and BIRDS folders
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /([^/]+/)*index\.php\%3[fF]folder\%3[dD]([^\ ]+)\ HTTP/
RewriteRule ^cats/index\.php http://www.example.com/cats/index.php?folder=%2 [R=301,L]
RewriteRule ^dogs/index\.php http://www.example.com/dogs/index.php?folder=%2 [R=301,L]
RewriteRule ^birds/index\.php http://www.example.com/birds/index.php?folder=%2 [R=301,L]
I am at loss as to why DOGS will work but CATS will not. Can anyone shed some light on this for me? Please remember that I am not using the second simplified code now but an still trying to get the three seperate RewriteCond and RewwriteRule commands working.