weierophinney wrote:
> 
> This is an interesting idea, but I have no plans to implement it in the
> 1.x branch. In 2.0, you will have the option of defining your own
> decorator chains as classes -- which means that you should be able to
> specify the name of a decorator chain class when defining an element,
> and it will use that. This allows you to define the chain once, and use
> it simply many times.
> 
Thanks for your reply, Matthew.

Isn't that basically the same as doing:

class MyForm extends Zend_Form
{
    public function init()
    {
        $decorators = array('ViewHelper', 'Label', 'Whatever');
        
        $element1 = new Zend_Form_Element_Text();
        $element1->setDecorators($decorators);
        
        $element2 = new Zend_Form_Element_Text();
        $element2->setDecorators($decorators);
    }
}

? Still means you have no control of the default decorators (i.e. you have
to specify them each time you create an element).
-- 
View this message in context: 
http://n4.nabble.com/How-to-set-the-default-decorators-for-form-elements-tp1290314p1569132.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to