Welcome to Pull Digital's technology blog Syntax*.

Content Migration Project in ASP.NET?

If you implement URL redirection in the form of a look up table and in the C# code you use the ASP.NET Response.Redirect() method to call the new URL based on a 404 error of an old one, there will be one problem: This method doesn't notify Google that the URL redirect is permanent.

It's important to set the return HTTP status code to 301.

Relating this to code. Where you have your Response.Redirect(url) line, above it put:

"Response.StatusCode = 301;"

With the more advanced ASP.NET 4.0 Framework a simpler method has been provided, although the above code will also work:


More info:

Some Of Our Clients

  • First-Central
  • Boux-Avenue
  • Conversis
  • John-Lewis
  • EY
  • Kompan
  • Living-Streets
  • Meteor
  • OSI
  • Schwarzkopf
  • GoCycle
  • SSTL
  • Chaucer-Direct
  • TurtleMat
  • UK200Group
  • ASDA
  • Vinci
  • Zoggs

We Deliver Marketing CertaintyTM

Find Out More