I have a simple method
def activities
@headers[“Content-Type”] = “application/xml; charset=utf-8”
activities = get_activities
@feed = FeedTools::Feed.new
@feed.title = "Activities"
@feed.author = "Cogini"
@feed.copyright = "Cogini 2005-2006"
@feed.link = "http://localhost:3000/admin/customers/"
@feed.content = "Activities"
activities.each do |a|
@feed_item = FeedTools::FeedItem.new
@feed_item.feed = @feed
@feed_item.content = activity_link(a)
@feed.entries << @feed_item
end
render :inline => "<?xml version='1.0'
encoding=‘UTF-8’?>\n#{@feed.build_xml(‘rss’, 2.0)}"
end
That builds a feed from a set of fixed values + some dynamic data, but I
cannot get it to build the correct rss.
@feed.build_xml returns a string - not the XMLBuilder as promised, so I
simply concatenated the xml header and tried to render, but now I get a
DoubleRenderError - I can’t see anywhere else in this where I render
previously
I’ve also looked at the xml howto and the feedtools tutorial, neither of
them adequately explain how to do what I want - indeed following them
hasn’t brought me any closer to getting this working
Kev