This project is archived and is in readonly mode.

#6649 new
Xavier Shay

[PATCH] Add #updated support to entries in atom_feed

Reported by Xavier Shay | March 30th, 2011 @ 11:09 AM

This is minor, but important! I will explain in code, it will be easier than words. See the commented lines, the second one is currently broken (outputs invalid data):

atom_feed(:schema_date => '2008') do |feed|
  feed.title("My great blog!")
  feed.updated(@scrolls.first.created_at) # <--- This currently works

  for scroll in @scrolls
    feed.entry(scroll) do |entry|
      entry.title(scroll.title)
      entry.updated(Time.utc(2007, 1, scroll.id)) # <---- This patch allows this to work
      entry.content(scroll.body, :type => 'html')

      entry.author do |author|
        author.name("DHH")
      end
    end
  end
end

No comments found

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments

Tags

Pages