I checkt the header status of the redirect with the following tool
http://www.seoconsultants.com/tools/headers.asp
and noticed it response a 302 redirect.

Using a 302 redirect for this is not the good choice. It should be a 301 move permanantly.
See
http://www.bigoakinc.com/blog/when-to-use-a-301-vs-302-redirect/
http://www.mattcutts.com/blog/seo-advice-discussing-302-redirects/

How to change the 302 to a 301?

CommentFileSizeAuthor
#2 referral_301_redirect.patch744 bytesJackinloadup

Comments

GregCTU’s picture

I'm confused, why did they choose to use 302 as opposed to 301s for the url alias module?

Jackinloadup’s picture

Status: Active » Needs review
StatusFileSize
new744 bytes

I agree the links should have 301 redirects.

After a little digging it looks like User Referral used drupal_goto to redirect the user to the correct page. According to the API docs (http://api.drupal.org/api/function/drupal_goto) we can make these redirects a 301 redirect pretty easily.

I have included a patch that makes the necessary changes.

I think this is the proper way to do the redirect. Please review and comment!

Also my referral path is set to a url that is controlled by securepages (http://drupal.org/project/securepages) This module also does a 302 redirect. I filed an issue and patch to change their redirect to a 301. http://drupal.org/node/506522

On a related note, maybe the User Referral admin page should contain a setting to set if the referral path is https or not. This would only be to help avoid 2 redirects when in use with a solution like securepages.
As is stands now the process is like so:
referral redirect -> securepages redirect ->destination

this would allow a shorter (faster?) path to the end.
referral redirect -> destination
I dont know how this affects SEO or speed but it seems cleaner.

So not a huge deal.. just a thought.

alliax’s picture

As of today, 11th october 2010, your patch hasn't been applied to referral module, why is that?
I applied your patch, I think it makes sense if you don't want to have referral urls indexed in google and if you want to get the juice of all the backlinks..