Code from the screent cast.    http://net.tutsplus.com/tutorials/ruby/the-intro-to-rails-screencast-i-wish-i-had/