Try Now
More in this section

Forums / General Discussions / Display custom field in news rss feed

Display custom field in news rss feed

2 posts, 0 answered
  1. shraddha
    shraddha avatar
    87 posts
    18 May 2009
    17 Jun 2010
    Link to this post
    I am using sitefinity 3.7 SP3.
    I have created custom RssChannelProvider for news as I wanted to hide comments.
    I am inheriting GetRSSItems methods as below

    public override System.Collections.Generic.IList<RssItem> GetRssItems(System.Collections.Specialized.NameValueCollection query)
            IList<RssItem> Items = base.GetRssItems(query);
            foreach(RssItem i in Items)
                i.Comments = "";
            return Items;
    I have custom column in news section as 'FileName'. And I want to display that column in RSS feed. How can I achieve this???

  2. Radoslav Georgiev
    Radoslav Georgiev avatar
    3370 posts
    01 Feb 2016
    22 Jun 2010
    Link to this post
    Hi shraddha,

    You can pass the value of the custom field to the i.Comments using content.GetMetaData() method in an override to the bello method:
    protected override void SetGeneralProps(Telerik.Rss.RssItem item, IContent content)
        base.SetGeneralProps(item, content);
        //add logic here

    Kind regards,
    Radoslav Georgiev
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
2 posts, 0 answered