DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Tatjana has posted 5 posts at DZone. View Full User Profile

Full Error Messages

06.06.2008
| 223 views |
  • submit to reddit
        
class User < ActiveRecord::Base
  validate do |user|
    user.errors.add_to_base("Country can't be blank") if user.country_iso.blank?
  end
end
<%= error_messages_for :game, :header_message => "Please Try Again!", :message => "We had some problems starting the game:" %>