For some reason this is not working…
Options +FollowSymLinks -MultiViews -Indexes
RewriteEngine On
RewriteBase /
Redirect 301 "/modules.php?name=News&file=article&sid=179" http://www.mysite.com/a/new/url
I have no idea why… If I replace the URL being redirected with another non-existent one (/helloworld) it redirects fine to the new url..
Is it catching on something? I tried escaping (/modules.php\?name=News&file=article&sid=179) but it didn’t make any difference, still just 404s.
any help is appreciated!
You can’t match against the query string in the
Redirectdirective, you’ll have to use mod_rewrite and the%{QUERY_STRING}variable. Try this: