you are in: codestackercodes [RSS]humanized attributes

humanized attributes Delicious Email

show/hide lines
   1  class User < ActiveRecord::Base
   2  
   3    HUMANIZED_ATTRIBUTES = {
   4      :email => "E-mail address"
   5    }
   6  
   7    def self.human_attribute_name(attr)
   8      HUMANIZED_ATTRIBUTES[attr.to_sym] || super
   9    end
  10  
  11  end
created by leozera — 22 August 2009 — get a short url — tags: rails ruby embed

Comments



We dont send spam :)

If checked, it's highlights your comment
simple_captcha.jpg
Are you a human? Type the code from the image