Mod_rewrite .htaccess Redirect Part Of A Query StringNov 9, 2010
I'm struggling with a redirect problem. I need to redirect the following URL with mod_rewrite thorough .htaccess [URL] to the following [URL] So, basically I just need to remove the
However, the order is important. Sometimes
appears after other variables in the querystring. in this scenario I need the
to remain part of
Is this possible? To summarise, if &lang=php appears at the beginning of the query string, remove the &. If &lang=php appears anywhere else in the query string, the & must remain. I would change the script myself but unfortunately I am not the developer, and he doesn't seem too helpful at the moment; this is a quick fix.