External RSS ContentProvider example for #EPiServer, Part three

I’ve experience that it can be tricky setting up content provider. Content Providers in EPiServer is a way of publishing external data as pages/blocks etc. Here is an example of an RSS Content Provider.

This RSSContentProvider derive from an old CMS 6 example of the XMLPageProvider documented here http://world.episerver.com/documentation/Items/Tech-Notes/EPiServer-CMS-6/EPiServer-CMS-60/XmlPageProvider/

Result: listing the RSS as pages

Firstly LoadChildrenReferencesAndTypes is called if not cached, mapping up all the providers ContentReference in EPiServer with MappedIdentity.ConstructExternalIdentifier and IdentityMappingService.

Secondly all ContentReference are call thru LoadContent, where the content is created.

ListMatchingSegments is used by the routing system to match the url segment with the ContentReference.

You’ll need an EPiServer page with equivalent properties “IntroText”, “MainBody” and “DocumentUrl”.

Register the provider in web.config:

RSS Content Provider C# Code:

Find the code also on gist github: https://gist.github.com/LucGosso/

This blogpost is a continuation of a series of blog posts on Content Providers, former Page Provider for EPiServer:

Contentprovider example for #EPiServer, Former PageProvider, Part one

Like it? please up vote