OSDN Git Service

553f344fdcb5e4fdd1329da14a13f7f0db89dcb6
[pettanr/pettanr.git] / app / views / scrolls / show.rss.builder
1 xml.instruct!
2  
3 xml.rss("version"    => "2.0",
4         "xmlns:dc"   => "http://purl.org/dc/elements/1.1/",
5         "xmlns:atom" => "http://www.w3.org/2005/Atom") do
6   xml.channel do
7     xml.title       MagicNumber['profile']['users']['caption']
8     xml.link        root_url
9     xml.pubDate     Time.now.rfc822
10     xml.description sanitize(MagicNumber['profile']['users']['description'], :tags => %w(a p img br))
11     xml.atom :link, "href" => @rss_url, "rel" => "self", "type" => "application/rss+xml"
12  
13   @comic.stories.each do |story|
14       xml.item do
15         xml.title        story.panel.caption
16         xml.link         panel_url(story.panel)
17         xml.guid         panel_url(story.panel)
18         xml.description  story.panel.plain_scenario
19         xml.pubDate      story.panel.updated_at.to_formatted_s(:rfc822)
20         xml.dc :creator, story.panel.author.name
21       end
22     end
23   end
24 end