Issues with Redirection and HTACCESS
Good Day and Thanks for any assistance:
I have two url's:
- New URL
As you can see the site changes from .com to .ca and on the new URL there is a HTML page inserted into the URL.As well the ?id is changed to ?psid as well.
I have looked at many examples but there is none that has just the page in the new url. Could someone assist me in the .htaccess file and making this work.
Thanks
Steve Fulton, UE
-
Hey there! Those type of URLs indicate there is some application (Wordpress, Joomla, etc.) running on the site, so it might be better to see if the URLs can be fixed or adjusted directly in the app than to try and manipulate them with .htaccess. 0 -
Hi there Thanks for the message, Unfortualty the old URL came from FoxPro and it is no longer available. The new URL is straight HTML. Is there anyway to resolve this? If not i am going to have to rewrite 1.9 million MYSQL lines to resolve. Thanks Steve 0 -
Thanks for the assist in this. I am reviewing the link and hopefully can resolve the issue. Thanks Steve 0 -
Hello, if you put something like that in your .htaccess at my-site.com it should do what you want: RewriteEngine On RewriteCond %{REQUEST_URI} ^/view$ RewriteCond %{QUERY_STRING} ^id=([0-9]*)$ RewriteRule ^(.*)$ https://my-site.ca/search-item.html?psid=%1 [R=302,L]0
Please sign in to leave a comment.
Comments
5 comments