Wednesday, March 21, 2012

How to create RSS in ektron CMS

Here i will show how to create a RSS for collection data in Ektron cms.In ektron cms we have an option ecmRssCollection method to get the data to rss feed object.There one more server control i:e RSSagrregator is also used to ge the rss feed data.I have collection control in my results page.When ever click on the Rss feed the query string value is passed to the rss page .The rss page shouldn't have HTML content.By default the aspx page has HTML content so we have to remove the content in this page.If we don't remove the html content in page we not get the rss data in Chrome browser.The 15 is the collection default ID in work area

if (Request.QueryString["rss"] == "collectionDatatest")
{
object rssFeedData = null;
Ektron.Cms.UI.CommonUI.ApplicationAPI AppCUI = new Ektron.Cms.UI.CommonUI.ApplicationAPI();
rssFeedData = AppCUI.ecmRssCollection(15)
Response.ContentType = "text/xml";
Response.Write(rssFeedData);
}
Post a Comment

Bel