Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsProvidersProvidersPlease help a noob with UrlProviders!Please help a noob with UrlProviders!
Previous
 
Next
New Post
8/14/2015 2:39 PM
 

Hi there,

I only discovered DNN this week and it seems like a perfect fit for a new development project we're working on which involves converting an old vanilla ASP.NET site into something a bit better :)

I started working with the platform today and have successfully created a site and started tinkering around with the templates in Visual Studio. I downloaded Christoc's DotNetNuke Module templates and after a bit of messing around have managed to get the project building and generating the Extension package files for loading into the platform. So far so good.

One of the main requirements for this project are to keep the URLs consistent with the old site and regardless we will have to do some URL rewriting to implement some of the more advanced functionality.

I decided that a first port of call then would be to create a basic test implementation of some simple re-writing to make sure I can get DNN to do what we want. I downloaded the DNN.UrlRedirectProvider project and after a bit more tinkering I created a new UrlProvider based on this project inside my Module project.

Things I did:

  • Copied all classes from the UrlRedirectProvider project into my new Module project and changed all namespaces accordingly
  • Added a <Component> entry into my .DNN file for the UrlRedirectProvider
  • Set redirectAllUrls, replaceAllUrls and rewriteAllUrls parameters to be true in the manifest
  • Modified the ChangeFriendlyUrl() method adding a simple rule to change one of my Urls using a string.Replace()  - From "Example-Url" -> "New-Url"
  • Added a debug message to the messages parameter
  • Built the package and installed into my DNN deployment via the wizard

Now when I look under Site Settings > Advanced Url Settings I can see the new UrlProvider listed and it is ticked. However it doesn't seem to be doing anything at all and there are no debug messages appearing in the response header. I even tried to throw an exception in the ChangeFriendlyUrl() method hoping that this would crash the whole site but that did nothing.

Have I missed something obvious here? I'm tearing my hair out with this and getting nowhere. Any help would be very very much appreciated!

huge thanks in advance.

 Olly

 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsProvidersProvidersPlease help a noob with UrlProviders!Please help a noob with UrlProviders!


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out