Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

We are rolling up content from multiple site collections and are looking for a way to allow a RSS feed from that rolled up content. Any ideas on implementation of a RSS option for a custom webpart? I know the Content Query Web Part has an option to subscribe to it via RSS and am looking to implement that on a custom web part.

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

I think you'll need an application page (_layouts page) for this that returns the xml needed for the feed. If you've seperated the data/business logic from your presentation layer in your webpart, then this application page should be pretty easy to write because you are just creating a new XML based presentation layer.

share|improve this answer
add comment

As @Steve mentioned, create an Application Page in the _Layouts folder that outputs the RSS feed. Then link to that page from your web part. Here is an example of how to generate an RSS feed from C#: http://www.dailycoding.com/Posts/create_rss_feed_programatically_from_data_in_c.aspx

share|improve this answer
    
Thanks for the additional information and post. I was hoping to keep the logic for querying the data in just the web part. I hadn't thought of using an application page, but I guess I could create a generic one that takes parameters from the web part. –  Jason Jones Sep 16 '11 at 15:47
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.