By j0k3z on
Im trying to do a 301 redirect in my htaccess to redirect oldfile.htm to mydomain.com/new-path but when I hit that old file to check it I am taken to mydomain.com/new-path?q=oldfile.htm How can I get ride of the ?q=oldfile.htm so that it works properly.
This is what I have in my .htaccess
"Redirect 301 /oldfile.htm http://www.mydomain.com/new-path"
Comments
I just had the same issue
I just had the same issue and found an answer:
In the file, you will find the commands:
Immediately after that code -- and before the Drupal-provided "Rewrite old-style URLs" commands -- add your rewrite rules using the following format:
The original poster had a leading / on the old/URL/path but that didn't work for me...taking off the slash fixed it.
Got it from here
Worked like a charm.
Modern Jurist: A Site For Lawyers