-- Dennis Becker <[EMAIL PROTECTED]> wrote
(on Tuesday, 19 February 2008, 01:54 PM +0100):
> I have created a small form for testing the new Zend_Form component. Can 
> anyone
> tell me, why I cannot set the "value" property for a 'submit' button? Instead,
> the 'submit' button uses the value for 'label' and I cannot deactive the label
> for 'submit'. For me it looks like a bug, but I'm not sure.

This is by design.

We use the label of the element, as this is what is *displayed* to the
end user. It also allows us to check the submitted value against the
label to determine (a) if the given submit button was used, and/or (b)
if somebody's potentially monkeying with the form. As an example,
Zend_Form_Element_Submit::isChecked() checks the submitted value
against the label, for instance; if they match, isChecked() returns
true.

-- 
Matthew Weier O'Phinney
PHP Developer            | [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/

Reply via email to