LibrarySites.Banner

All About RSS Feeds with the Sitecore ASP.NET CMS | John West | Sitecore Blog

This blog post attempts to contain or link to everything I know or could find about RSS with the Sitecore ASP.NET web Experience Platform and Content Management System (CMS).

I have seen several types of questions about RSS with Sitecore:

  • What are some good RSS feeds about Sitecore?
  • Render RSS feed as HTML
  • Produce internal RSS feeds about items in workflow
  • Produce public RSS feeds about content items

RSS Feeds about Sitecore

I think the best long-term RSS feed about Sitecore may be http://feeds.sitecore.net (RSS http://feeds.sitecore.net/feed/LatestPosts). If anything is missing from that feed, please report it to @markvanaalst. If the content you expect does not appear, then please contact me directly, such as by messaging @sitecorejohn or by commenting on this blog post.

Rendering RSS as HTML with Sitecore

Some solutions need to render an existing RSS feed as a page or a component of a page of their Site managed by Sitecore. When you use XSL renderings (see the Resources section at the end of this blog post) or render RSS as HTML with ASP.NET Web Forms and MVC techniques, you have the option of using Sitecore output caching to improve performance. With any of these technologies, you have complete control of the output you generate from RSS input.

Sitecore Workflow RSS Feeds

The Sitecore Content Author’s Cookbook and especially the Client Configuration Cookbook provide sufficient information regarding internal RSS feeds about items in workflow. Note that you can use RSS clients including Microsoft Outlook to subscribe to RSS feeds about the workflow status of items in Sitecore.

Public RSS Feeds with Sitecore

Most questions about RSS with Sitecore involve generating feeds about content items for public consumption. These requests may involve customizing individual entries in the feed or customizing the feed itself.

How Sitecore Public RSS Feeds Work

Sitecore uses feed definition items based on the System/Feeds/RSS Feed data template to define RSS feeds. In feed definition items, layout details for the default device specify the Layout/Layouts/System/Feed Delivery Layout, which in turn specifies the /sitecore/shell/Applications/Feeds/Layouts/FeedDeliveryLayout.aspx layout file. This file contains nothing other than a Page directive that specifies the Sitecore.Syndication.Web.FeedDeliveryLayout base class. The FeedDeliveryLayout class uses the Sitecore.Syndication.FeedManager class to render the feed. You could implement your own FeedDeliveryLayout, and you could use alternate managers to render the feed.

If the feed definition item specifies a value in the Type field, then the feed manager uses that type to render the feed. The feed manager uses the Sitecore.Syndication.PublicFeed class to render the feed by default if the item does not specify a Type. For each item in the feed, the PublicFeed class adds the rendering control specified for the first presentation component bound to a placeholder for the Feed device, which is typically the Sitecore.Web.UI.WebControls.FeedRenderer web control. You could implement your own classes that inherit from PublicFeed, and you could implement your own web controls that derive from FeedRenderer.

Customizing items in the feed generally involves the FeedRender Web Control. Examples include:

  • Controlling how Sitecore renders values in the field, such as escaping special characters
  • Controlling which fields Sitecore renders

Customizing entire feeds generally involve the PublicFeed class. Examples include:

  • Controlling which items appear in the feed
  • Controlling the sorting of items in the feed
  • Controlling how Sitecore caches the feed

Conclusion

The resources linked in the following section contain greater detail, including anything more that I could think to write about RSS feeds with Sitecore. If you have more information or know about additional resources for working with RSS in Sitecore, please comment on this blog post.

Resources