Page 2 of 2

Re: 301 redirect old url to new .htaccess error

Posted: Wed Oct 15, 2014 3:33 pm
by diwakar007
I also tried this one

Code: Select all

RewriteEngine on
RewriteRule ^sitemap$ index.php?route=information/sitemap [R=301,L]
but it doesn't work.

Re: 301 redirect old url to new .htaccess error

Posted: Thu Oct 16, 2014 6:12 am
by Cue4cheap
diwakar007 wrote:I also tried this one

Code: Select all

RewriteEngine on
RewriteRule ^sitemap$ index.php?route=information/sitemap [R=301,L]
but it doesn't work.

How about trying:
RewriteRule ^sitemap.xml$ /index.php?route=feed/google_sitemap

Mike

Re: 301 redirect old url to new .htaccess error

Posted: Fri Oct 17, 2014 8:33 pm
by diwakar007
Cue4cheap wrote:
diwakar007 wrote:I also tried this one

Code: Select all

RewriteEngine on
RewriteRule ^sitemap$ index.php?route=information/sitemap [R=301,L]
but it doesn't work.

How about trying:
RewriteRule ^sitemap.xml$ /index.php?route=feed/google_sitemap

Mike

Thanks for the reply Mike, But this is not "sitemap.xml" URL it's a "sitemap.html". Because in opencart it exclude the ".html" from every webpage. That's why I write the code above.

Re: 301 redirect old url to new .htaccess error

Posted: Thu Jan 15, 2015 11:39 am
by MarketInSG
If anyone requires a quick way to set up redirection, do have a look at this: http://www.opencart.com/index.php?route ... n_id=20467

Re: 301 redirect old url to new .htaccess error

Posted: Tue Sep 22, 2015 2:41 pm
by xoomit
Hi,

I have the same problem but with 2 shops. I want to set 301 to forward URLs from my old shop to the new one, for example:

Redirect 301 /rechtliche-fragen-beim-guerilla-gardening.html https://www.diestadtgaertner.de/blog/re ... -gardening

The shops run on two domains and the redirect will happen in the htaccess of the old shop. The old shop runs on 1.5.6 the new one on 2.01.1. Many URLs change in the new shop so I couldn't use placeholders.

Any idea how this could be done?

Thanks & best,
Torge

Re: 301 redirect old url to new .htaccess error

Posted: Thu Oct 06, 2016 1:57 pm
by Madhavi
Could you please fix these links in opencart
1. HOME: http://nails.hollywoodessentials.com/in ... ommon/home
SHOULD BE: http://www.nails.hollywoodessentials.com/home

2. Contact Us: http://nails.hollywoodessentials.com/in ... on/contact
SHOULD BE: http://www.nails.hollywoodessentials.com/contact-us

My products pages are working with seo friendly url but these urls are not working.Please solve my problem.

Re: 301 redirect old url to new .htaccess error

Posted: Mon Oct 10, 2016 3:23 pm
by HariOm108
Please help to make redirect command from old page

/shop/dekorativnye-plenki?route=product/category&path=25

to new page
/dekorativnye-plenki

Tnanks!

Re: 301 redirect old url to new .htaccess error

Posted: Sun Dec 11, 2016 11:20 pm
by frank79
For the ones that have troubles with redirecting SEO urls, I have read about the question mark (?) trick, but the way to go is to work with the query variable _route_ :

In your htaccess, find the line:
RewriteBase /

And just after that copy and paste this rule, replacing old-seo-url and new-seo-url with your urls:

RewriteCond %{QUERY_STRING} _route_=OLD-SEO-URL
RewriteRule ^index\.php$ /NEW-SEO-URL? [R=301,L]

Re: 301 redirect old url to new .htaccess error

Posted: Sat May 20, 2017 11:58 am
by artgarcia
frank79 wrote:
Sun Dec 11, 2016 11:20 pm
For the ones that have troubles with redirecting SEO urls, I have read about the question mark (?) trick, but the way to go is to work with the query variable _route_ :

In your htaccess, find the line:
RewriteBase /

And just after that copy and paste this rule, replacing old-seo-url and new-seo-url with your urls:

RewriteCond %{QUERY_STRING} _route_=OLD-SEO-URL
RewriteRule ^index\.php$ /NEW-SEO-URL? [R=301,L]
frank79 Just did it and it works just fine! thanks!

ArtGarcia
profitnessmx.com
mexico