UnprotectAttributes =================== Copyright 2008 t.e.morgan. License: MIT Updates/info: http://iprog.com/project/unprotect_attributes Contact: tm@iprog.com A plugin to add methods to ActiveRecord to modify all attributes, including protected ones. This is useful where some attributes are protected for general user access, but a separate admin controller should be able to update everything. Installation: Simply add this plugin into your rails app. To add to your rails app: ./script/plugin install http://svn.iprog.com/projects/rails/plugins/unprotect_attributes Methods: protected_attributes=(attributes) Use just like attributes=. Example: @user.protected_attributes = {:role=>'admin'} update_protected_attributes(attributes) // update_protected_attributes!(attributes) Use just like update_attributes and update_attributes!. Example: @user.update_protected_attributes :role=>'admin' Other Notes: Tested only with Rails 2.1, although I suspect it will work with 2.0 and 1.2. If you find a bug, have a suggestion, or just want to tell me that it works, I'd love to hear from you. Thanks for checking unprotect_attributes out! --t (tm@iprog.com; http://iprog.com/)