public
Description: Add humanity to Rails ActiveRecord column names.
Homepage: http://blog.ashchan.com/archive/2008/11/24/rails-i18n-activerecord-model-human-name-made-easy/
Clone URL: git://github.com/ashchan/humanize_attributes.git
name age message
file MIT-LICENSE Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
file README Mon Nov 24 05:54:30 -0800 2008 updated readme: introduce I18N of Rails 2.2 [ashchan]
file Rakefile Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
file init.rb Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
file install.rb Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
directory lib/ Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
directory tasks/ Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
directory test/ Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
file uninstall.rb Mon Nov 24 04:32:28 -0800 2008 initial commit [ashchan]
README
HumanizeAttributes
==================

Add humanity to Rails ActiveRecord column names.


Example
=======

  humanize_attributes :login => "User Name",
                      :password => "Secret Key"

Look for a more elegant way?
=======

Rails 2.2 has brought us powerful I18N, now we can localize ActiveRecord model names very easily, just drop the 
following in the config/locales/en.yml:

  en:
      activerecord:
          models:
              user: "Member"
          attributes:
              user:
                  login:    "User Name"
          password:  "Secret Key"
          
See [here](http://blog.ashchan.com/archive/2008/11/24/rails-i18n-activerecord-model-human-name-made-easy/) for more 
details.

Credits
=======

The original idea came from [Changing human attribute labels in Rails validation 
messages](http://fatvegan.com/2008/05/13/changing-human-attribute-labels-in-rails-validation-messages/).

Copyright (c) 2008 James Chan, released under the MIT license