Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Pauli Østerø 6 posts 28 karma points
    Aug 17, 2010 @ 19:39
    Pauli Østerø
    0

    Changes to SiteMapProvider

    The SiteMapProvider shipped with Umbraco is pretty basic and not very well maintained 

    http://umbraco.codeplex.com/workitem/26624
    http://umbraco.codeplex.com/workitem/28239

    But implement my own provider is problematic. Not because its hard to make your own, but because of the hard dependency there is on the shipped UmbracoSiteMapProvider-class

    1. The class is sealed
    2. There is hard references to the class in several places in the framework
    The reason for issue number 2 seems to be because of managing caching when adding or removing nodes or rolesin the backend which makes sense. This can be handled more elegantly, and without breaking anything, with an interface. I therefor suggest introducing the following interface
    public interface IUpdatedableSitemap {
       void RemoveNode(int nodeID);
       void UpdateNode(Node node);
    }
    This way we break the hard dependency on UmbracoSiteMapProvider and opens up for developers to make their own providers, WITHOUT loosing the flexibility of having the framework noticing these customs providers of any changes in the backend.

    Please discuss my proposal here and vote here http://umbraco.codeplex.com/workitem/26624, since this is really an issue that annoys me very much.

    I have several custom build SiteMapProviders with hooks to populate dynamic content and i use them all the time to render website menus, sitemap for searchengines (http://www.sitemaps.org), sitemaps for visitors etc. etc.

Please Sign in or register to post replies

Write your reply to:

Draft