DotDragnet
May 22, 2012, 02:41:30 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: follow us on twitter @dotdragnet
 
   Home   Help Search Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: 301 Redirects?  (Read 1492 times)
slaughteredlamb
DDN Contributor
Hero Member
*****
Posts: 1089



peakoverload
View Profile WWW Awards
« on: February 08, 2008, 03:21:43 PM »

Long story short. Site change means that some URL's that Google and other sites have are now slightly different to the ones they are now and so they get a 404. How can I set-up a redirect so that the old URL now points to the new one?

I've tried adding:

redirect 301 /old/old.htm http://www.you.com/new.htm

to my .htaccess but that's not working.

Is there anything else I can do?
Logged
Mr Anderson
DDN Contribs
Hero Member
*****
Posts: 2267



ap4a.uk ap4a
View Profile WWW Awards
« Reply #1 on: February 08, 2008, 03:29:45 PM »

Replace "301" with "permanent" and see if that makes a difference - that format works for me.
Logged

slaughteredlamb
DDN Contributor
Hero Member
*****
Posts: 1089



peakoverload
View Profile WWW Awards
« Reply #2 on: February 08, 2008, 04:25:54 PM »

Ahh I tried that and that didn't work either but then I tried another URL and that did work so I think it's down to this particular URL.

The OLD URL is:
www.peakoverload.com/blog/photography/lastolite-ezybox-%11-hotshoe.html

Which is an old SEF generated URL based on the articles title etc which is lastolite ezybox - hotshoe.

The OLD SEF component I used replaced all spaces with - and I guess changed the - in the title to %11.

The NEW SEF URL is:

www.peakoverload.com/myblog/lastolite-ezybox-hotshoe.html

If I enter

redirect permanent /blog/photography/lastolite-ezybox-%11-hotshoe.html http://www.peakoverload.com/myblog/lastolite-ezybox-hotshoe.html

This doesnt work because, I think, of the %11 bit. Is there a solution to this? If not it's not that big a deal as it's the only article that is affected in this way.

Cheers for the help!
Logged
JasonD
Global Moderator
Hero Member
*****
Posts: 546



View Profile Awards
« Reply #3 on: February 08, 2008, 05:31:43 PM »

You'll need to replace the %11 with an actual 0x11 control character. If the board doesn't break this

redirect permanent /blog/photography/lastolite-ezybox--hotshoe.html http://www.peakoverload.com/myblog/lastolite-ezybox-hotshoe.html
Logged
slaughteredlamb
DDN Contributor
Hero Member
*****
Posts: 1089



peakoverload
View Profile WWW Awards
« Reply #4 on: February 10, 2008, 09:09:28 PM »

Mr Jason Sir. Only just seen your reply. That worked a charm! Thank you very much!!%11!!
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2006-2008, Simple Machines Valid XHTML 1.0! Valid CSS!