Jump to content

  • Log in with Facebook Log in with Twitter Log In with Google      Sign In   
  • Create Account

Subscribe to HRA Now!

 



Are you a Google Analytics enthusiast?

Share and download Custom Google Analytics Reports, dashboards and advanced segments--for FREE! 

 



 

 www.CustomReportSharing.com 

From the folks who brought you High Rankings!



Photo
- - - - -

Permanent 301 Redirect


  • This topic is locked This topic is locked
320 replies to this topic

#106 magicboxgifts

magicboxgifts

    HR 4

  • Active Members
  • PipPipPipPip
  • 117 posts
  • Location:Leicester UK

Posted 09 February 2005 - 01:19 PM

QUOTE(Randy @ Feb 8 2005, 12:52 PM)
If your file names remained constant except for the extension change, the easiest way to do that is:
CODE
RedirectMatch 301 (.*)\.html$ http://www.yourdomain.com$1.php


What that does is take any request for <anyfilename>.html and automatically redirects to <anyfilename>.php
View Post


Hi Randy, tried this but to my horror eek.gif when I came back to the office today and ran my first checks all my pages were being directed to my error page.

I should have mentioned that my stats package pages and catalogue are all HTML

OOOPs

cheers for any advice, I have thus removed this from my .htaccess....

#107 Randy

Randy

    Convert Me!

  • Moderator
  • 17,540 posts

Posted 09 February 2005 - 02:07 PM

We'll need to sort out a more elegant solution for you then MBG.

Is there any common ground we can work with rather than having to list each of the old .html pages that are now .php pages? Like are all of the new php pages in the root directory? Or are all of the stats and catalogue (and other .html pages that are still available) in specific sub-folders that we can exclude from the redirect?

#108 magicboxgifts

magicboxgifts

    HR 4

  • Active Members
  • PipPipPipPip
  • 117 posts
  • Location:Leicester UK

Posted 10 February 2005 - 03:32 AM

Hi Randy

the structure is

../catalogue (all HTML)
../pages (all now php)
../index.php

due to the nature of the cart I used (Actinic) I have forced all the internal links to become 'external navigation' back to the main site as the software likes to include everything into acatalogue?!

So as for exlusion , the folder pages is OK to exclude I would imagine

I mus be honest, the only way around it I could see was to list all the old pages eek.gif

Cheers
Daren

#109 dominicsp

dominicsp

    Dominic P

  • Active Members
  • PipPipPipPip
  • 137 posts
  • Location:India

Posted 18 February 2005 - 12:32 AM

QUOTE(mcanerin @ Apr 21 2004, 08:19 PM)
Since I'm apparently one of the few that uses MS Server I'll fill in the last blank. IIS handles this differently.

If you control the server, you open the Internet Services Manager, then choose the server running the site you want to forward.

Right click on the site and choose Properties > Home Directory

You will see the Following:
---------------------------------------------------
When connecting to this resource, the content should come from:
  • A directory located on this computer
  • A share located on another computer
  • A redirection to a URL
The default is the first one. Change it to "A redirection to a URL" and type in the new URL. Done.
Ian
View Post


Hi Ian,
Will it work fine if I do the same for individual pages whose names have been changed due to site restructuring

#110 chrishirst

chrishirst

    A not so moderate moderator.

  • Moderator
  • 6,869 posts
  • Location:Blackpool UK

Posted 18 February 2005 - 03:21 AM

Yes you can do individual files,
I've done a "howto" on all three. IIS Redirects.

#111 dominicsp

dominicsp

    Dominic P

  • Active Members
  • PipPipPipPip
  • 137 posts
  • Location:India

Posted 18 February 2005 - 06:16 AM

Thanks Chrishirst smile.gif

#112 dominicsp

dominicsp

    Dominic P

  • Active Members
  • PipPipPipPip
  • 137 posts
  • Location:India

Posted 18 February 2005 - 06:23 AM

Hi Chrishirst,
Can I keep the same content for the old page or should I create a blank page for it

Dominic

#113 Jill

Jill

    Recovering SEO

  • Admin
  • 32,940 posts

Posted 18 February 2005 - 08:34 AM

If you're redirecting, you don't actually have the page existing.

#114 dominicsp

dominicsp

    Dominic P

  • Active Members
  • PipPipPipPip
  • 137 posts
  • Location:India

Posted 22 February 2005 - 12:19 AM

Thanks Jill smile.gif
very true, I have used 301 redirects for some page which had duplicate content. I hope thats OK

#115 Bernard

Bernard

    HR 5

  • Active Members
  • PipPipPipPipPip
  • 302 posts
  • Location:Friendswood, TX

Posted 15 March 2005 - 03:56 PM

QUOTE(Randy @ Apr 20 2004, 10:02 PM)
...  A simple 301 Redirect would look something like:
CODE
Redirect 301 / http://www.yourdomain.com/
The above would take any request made to the domain it's installed on and send it off to "http://www.yourdomain.com/", appending any file name or directory structure to the URL string.

... the above will work, however I don't care for [it] much since [it] create[s] a loop.  In other words, regardless where someone is looking for the www or non-www address, they're going to get a 301 server header.  It's a kludge, but sometimes this is all we have to work with.


Would this be an effective way to protect a site from being a victim of 302 redirect hijacking?

#116 Randy

Randy

    Convert Me!

  • Moderator
  • 17,540 posts

Posted 15 March 2005 - 06:10 PM

Well. not really Bernard. Because you could do more harm than good if you end up throwing people into a loop.

There is some talk about using 301's to defeat page jacking attempts, and what I've read of the tactic makes some sense. However I've not tested it at all so I can't recommend it.

#117 chrishirst

chrishirst

    A not so moderate moderator.

  • Moderator
  • 6,869 posts
  • Location:Blackpool UK

Posted 15 March 2005 - 07:35 PM

You probably could negate the page jacking problem with a 301, but I would agree with Randy that it could be a risk in creating a loop by using a simple redirect.
To be on the safe side it would need a bit of UA detection and only send a 301 to the Googlebot. This shouldn't set up a loop because SE crawlers don't actually follow links. However it's purely theoretical as I don't have a hijacked page to test.
Might see if I can set one up deliberately smile.gif

#118 Randy

Randy

    Convert Me!

  • Moderator
  • 17,540 posts

Posted 16 March 2005 - 07:39 AM

hysterical.gif Chris !

I had one or two test hijacks I'd set up months --okay over a year-- ago just to see what to look for that would actually work. Just in case it ever happened to me, which is hasn't. I assume it's still much the same as it was back then.

I guess I could always fire those test pages back up for a few weeks and see if 301's will defeat my hijacking test. Let me know if you'd like me to test the theory too.

#119 chrishirst

chrishirst

    A not so moderate moderator.

  • Moderator
  • 6,869 posts
  • Location:Blackpool UK

Posted 16 March 2005 - 05:11 PM

Dan (Thies) has just posted this in a hijack thread at IHY Page Hijacks. Hopefully he won't mind.

Good info (if you like that kind of thing) nerd.gif mf_prop.gif

biggrin.gif

#120 Raphael

Raphael

    The Limey Cowboy

  • Active Members
  • PipPipPipPipPipPip
  • 722 posts
  • Location:New England

Posted 30 March 2005 - 04:41 PM

QUOTE(Ron Carnell @ Apr 22 2004, 07:50 PM)
This is one of those things that is done ONLY because search engines exist.

...

Redirecting an alias is a contradiction, and one that exists only because of the search engines.
View Post


Great post, Ron..

I just wanted to comment on this above point.

http://mysite.com/ and http://www.mysite.com/ are different sites, and so a PHP session won't transfer from one to another. That would be another reason for rewriting the alias in your browser's URL window.

Especially if you've only got one SSL certificate, for www.mysite.com and so all of your CC transactions need to be processed on that domain.....

(Can you tell what I'm busy coding atm?)

p.s. I remember Gopher.. And archie... =)




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

SPAM FREE FORUM!
 
If you are just registering to spam,
don't bother. You will be wasting your
time as your spam will never see the
light of day!