Zen Cart Logo
Forums / General Questions / Why wont this redirect work?

Why wont this redirect work?

Locked

Views: 1,701

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
6 Jul 2009, 5:10 PM
#1
plymgary1 avatar

plymgary1

Zen Follower

Join Date:
Feb 2009
Posts:
121
Plugin Contributions:
0

Why wont this redirect work?

I am trying to set up a 301 redirect on my site but i keep getting a 'redirect loop' error. I'm not sure why? I've got other redirects in place and they work fine (using similar coding). The code i'm putting in to htaccess is:

redirect 301 /ethnicgiftsbuddhistandtibetan-c-3_12.html http://www.handcrafteduk.com/

The page I am trying to redirect from does still exist but I didn't think that would cause the problem?

Any help appreciated.

Many thanks,

Gary :smile:

6 Jul 2009, 6:27 PM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Why wont this redirect work?

Might review this

RewriteEngine on
RewriteCond %{HTTP_HOST} ^firstddomain.com$ [OR]
RewriteCond %{HTTP_HOST} ^firstdomain-2.com$
RewriteRule ^(.*)$ http://www.maindomain.com/$1 [R=301]
6 Jul 2009, 8:00 PM
#3
plymgary1 avatar

plymgary1

Zen Follower

Join Date:
Feb 2009
Posts:
121
Plugin Contributions:
0

Re: Why wont this redirect work?

Hi Kobra,

Thanks for the reply. I've got that and it still does it. The strange thing is that other redirects work. :dontgetit

Here's an example:

redirect 301 /10ostrichfeathers-p-246.html http://www.handcrafteduk.com/whiteostrichfeathers-p-246.html
redirect 301 /ethnicgiftsrussian-c-3_14.html http://www.handcrafteduk.com/ethnicgiftsrussiandolls-c-3_14.html

6 Jul 2009, 10:41 PM
#4
plymgary1 avatar

plymgary1

Zen Follower

Join Date:
Feb 2009
Posts:
121
Plugin Contributions:
0

Re: Why wont this redirect work?

I've just tried to do it through my cpanel and got the following message:

Apache detected an error in the Rewrite config.

Syntax error on line 71 of /home/user/public_html/.htaccess.LxU3vrTy3cQiojBFbLXf2ZYuUw39XW5y:
RewriteCond> directive missing closing '>'

Please try again.

Any ideas?

6 Jul 2009, 10:47 PM
#5
mprough avatar

mprough

Totally Zenned

Join Date:
Nov 2007
Location:
Woodbine, Georgia, United States
Posts:
4,288
Plugin Contributions:
39

Re: Why wont this redirect work?

2 Things... redirect the live product is causing the loop... You see your SEO urls is also trying to redirect it.

Try adding your redirect above the rewrite syntax for your SEO urls.

~Melanie

6 Jul 2009, 11:08 PM
#6
plymgary1 avatar

plymgary1

Zen Follower

Join Date:
Feb 2009
Posts:
121
Plugin Contributions:
0

Re: Why wont this redirect work?

mprough:

2 Things... redirect the live product is causing the loop... You see your SEO urls is also trying to redirect it.

Try adding your redirect above the rewrite syntax for your SEO urls.

~Melanie

Melanie, you only went and bloody did it. Thank you. :clap::clap::clap::clap:

6 Jul 2009, 11:10 PM
#7
mprough avatar

mprough

Totally Zenned

Join Date:
Nov 2007
Location:
Woodbine, Georgia, United States
Posts:
4,288
Plugin Contributions:
39

Re: Why wont this redirect work?

Cheers!