Site Redirection with DNN Extension URL Providers

Views 4437

Recently I have been doing a lot of work with my new site and needed to do some consolidation work of my old Blog site to have all of my previous blogs redirected to my new site to allow me to keep the links and rankings that had been accumulated on the old site. My friend Bruce Chapman (B|T) wrote a nice little DNN extension – DNN Url Redirect Provider that is available for download from codeplex.

In this article I am going to take you through the steps you need to follow to utilise this DNN Extension to allow you to redirect any pages you have. Before you go down this track you do need to make sure that your version of DNN web site is 7.1 or later. If you are still working on an earlier version of DNN you will need to go through an upgrade process first. You can confirm your version by going to Host | Host Settings of your site.

First you will need to download the provider from codeplex but make sure you download version 1.01.01 or later so that you have no issues. Now we have the extension we need to install this extension. You will need to log in as Host on your site and navigate to Host | Extensions. From here you can use the Install Extension wizard to install the DNN Url Redirect Provider onto your site.


Once the installation of the Extension has completed you can confirm the provider is enabled for your site by navigating to Admin | Site Settings | Advanced URL Settings and confirm the DNN Url Extension Provider is enabled.

Inside of your SQL Server databases if you run this statement: “Select * from dbo.ExtensionUrlProviders” you should receive 1 row showing the provider is active.

Everywhere in this article where I mention and you will need to swap these for your respective sites you are performing this task for.

Second you will need to go to your server that is running IIS that your website is configured on. Starting IIS Manager and expanding the Sites tree until you can see your site ( Right click on your site and select edit bindings | Add and add details for the site to be redirected (  Click Close


Third you will need to create a new site alias in Still logged in as Host navigate to Admin | Site Management | Advanced Settings | Site Aliases Click Add New Alias entering and ensure that stays as your primary site alias.

Fourth you will need to identify the pages from that you want to have permanently redirected to In my case I was wanting to ensure that all of the blog posts on my old site were going to be permanently redirected to my new site. I had already brought across the blog posts and created them on my new site. With now knowing the pages to be redirected you can create your SQL Server insert statements. Your insert statements will look like this:

Insert Into dbo.urp_redirect 
([PortalId] ,[RedirectOrder] ,[HttpAlias] ,[RedirectUrl] ,[MatchType] ,[KeepQueryString] ,[DestTabPath] ,[DestTabId] ,[DestUrl] ,[DestType] ,[IsRegex])
(0 ,1 ,null ,'/Blog/EntryId/2/BlogTitle2.aspx','relative' ,0 ,null ,null ,'' ,'url' ,0);

The code snippet above will setup the redirection of to the explicit url –

There are other examples of how you can perform these redirects and you can look at them on the codeplex examples.

Fifth step in this process is for you to test the changes and ensure you are happy and that the right page is being redirected to the correct new location. For this you will need to modify your host file to contain the IP Address (of and Your host file entry would look something like this:

Before we can perform any tests we need to ensure that we have cleared the cache of Once again logged in as Host navigate to Tools | Clear Cache.


Last step before testing the redirection is to perform a restart of in IIS.

You should now be able to navigate to and it should be go to If everything has gone to plan the only thing left for you to do now is revert your host file entry from step 5 and to change your DNS A records for to point at

Good luck and hopefully you have found this helpful.

One response to “Site Redirection with DNN Extension URL Providers”

  1. chi tiết says:

    Great post. I am experiencing some of these issues as well..

Leave a Reply

Your email address will not be published. Required fields are marked *


I am a Microsoft Data Platform MVP as well as a Microsoft Certified Master working as the Principal Consultant here at SQL Masters Consulting. When I am not working with the SQL Server Stack I like to get away to the Snow and spend time Snowboarding.