This repository has been archived on 2020-05-27. You can view files and clone it, but cannot push or open issues/pull-requests.
barleysodas/app/views/beers/_beers.rxml

21 lines
715 B
Plaintext
Raw Normal View History

xml.instruct! :xml, :version=>"1.0"
xml.rss(:version=>"2.0"){
xml.channel{
xml.title("BarleySodas Newest Beers")
xml.link(beers_url)
xml.description("The newest beers added into BarleySodas.")
xml.lastBuildDate((@beers.first.created_at.strftime("%a, %d %b %Y %H:%M:%S %z") rescue nil))
xml.language('en-us')
for beer in @beers
xml.item do
xml.title(beer.title)
xml.description(beer.brewery.title)
xml.author(beer.page.created_by.title)
xml.pubDate(beer.created_at.strftime("%a, %d %b %Y %H:%M:%S %z"))
xml.link(beer_url(beer.page.title_for_url))
xml.guid(beer_url(beer.page.title_for_url))
end
end
}
}