htaccess; /search/?q=test to /test
- by Matthew Haworth
I have a similar situation to the one described in the title.
All that I need to do is map all requests in the form /search/?q=test to /test. This is because we are changing the way our search works to make it user friendly, but still want to allow for backward compatability (i.e. anyone that may have these links bookmarked etc).
However, thus far I have this:
RedirectMatch 301 /search/?q=(.*) /$1
And that doesn't work, but:
RedirectMatch 301 /search/(.*) /$1
does...
Any idea why?
Cheers.