Full code for the blog tutorial available on RubyOnRails.org.