Sitefinity ASP.NET CMS - Content Management System

Support Forum Thread

Home >  Support >  Forums home > Sitefinity 3.x > Deployment > 301 Redirections

Reply
Haydn, 6/22/2008 7:02:38 PM
Hi all,

I am in the midst of deploying a sitefinity instance, and this instance is to replace a old website that was written in PHP.

We are deployed to a different host, and plan to swap over the domain to refer to our new site.

Problem is, Google has indexed the old site, and we are taking over the domain, so naturally, we want to inform Google that the links within the
site have changed. We plan to be using a 301 redirection.  

My question is, how best can this 301 redirection be done within Sitefinity?

Ideally, we want to redirect the existing PHP page requests to applicable SiteFinity Pages for a select few old pages.

example:

http://www.somesite.com/somepage.php

301 redirects to

http://www.somesite.com/somepage.aspx

and anything we dont want to redirect will result in a 404.

Any advice on this would be appreciated.

Many thanks in advance


Reply
SelArom, 6/23/2008 8:32:26 AM
when you add a page to sitefinity you have the option of adding "additional urls" so that if users visit this via these additional urls, they will instead see the content of the sitefinity page Additionally, you can check a box that will enable redirection to the correct page (as opposed to just showing the correct content but the same old url) and if I am not mistaken this should be a 301 redirect.

hope that this was helpful!

Reply
Jeff, 6/23/2008 3:16:12 PM
Actually, the "Additional URLs" feature uses 302 (temporary) redirects, not 301 (permanent) redirects, according to this post.

302's aren't followed by Google.

I'm not sure if there's a Sitefinity solution for creating 301 pages. However, you could install PHP on the server and do the redirect using PHP scripting.

Reply
SelArom, 6/23/2008 3:54:40 PM
are you sure these redirects aren't 301? when the sf team said they'd implemented this feature, they were supposed to make it a 301. I don't know how you would check but that's what I was under the impression it was. can anybody from the sf team confirm?
Reply
Jeff, 6/23/2008 6:28:03 PM
You know, the end of that post I referenced says 301's will be included in SP2. I can't confirm that's actually the case, though. Probably best to hear it from SF themselves.
Reply
, 6/24/2008 5:31:17 AM
Hi,

Jeff and Josh,
The Additional URLs are in fact using 301 Redirects. If you follow up the thread provided by Jeff, you will notice that in the end of the thread we confirm it.

Haydn,
Everything that Josh mention is correct. I just want to add that you can put the following PHP code at the top of the pages located on your old domain, which will result a 301 Redirect to your new pages:

<?php 
header('HTTP/1.1 301 Moved Permanently');    
header('Location: '.$location); 
?> 

The $location variable holds the new address a string value.

Don't hesitate to contact us if you have other questions.

Kind regards,
Georgi
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center