Re: submit_tag ?

Nelson Hsu
2007-03-15T20:14:29Z

> I''m using the attr_protected macro.
>
> On Mar 15, 1:39 pm, Nelson Hsu
<rails-mailing-l...-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org>

From the documentation:

Attributes named in this macro are protected from mass-assignment, such
as new(attributes) and attributes=(attributes). Their assignment will
simply be ignored. Instead, you can use the direct writer methods to do
assignment. This is meant to protect sensitive attributes from being
overwritten by URL/form hackers.

So basically, attr_protected was designed specifically to prevent what
you want to do. :)

Nelson