I use a PHP script with my site that produces a querystring in the URL. One of the variables in the querystring is: colour=red
colour=red
I would like to make a rule i
RewriteEngine On RewriteCond %{QUERY_STRING} ^(.*&|)colour=red(&.*|)$ # search colour=red RewriteRule ^(.*)$ $1?%1colour=blue%2 [L,R=301] # redirect to colour=blue
This will redirect URLs with colour=red in query-string to URLs with colour=blue
colour=blue