Hector Virgen wrote:
> 
> I'm not sure if namespaces are supported by the plugin loader, can someone
> else confirm?
> 

Thanks for the help; however, I ended up building the custom element by
resetting and overriding decorators. It was as simple as:


        // define the "Save & Add Another" button
        $this->addElement('button', 'cancel', array(
            'description' => 'Cancel',
            'isArray'     => true,
            'belongsTo'   => 'goto', // this doesn't seem to work here -- is
it because I'm not using the ViewHelper decorator?
            'decorators'  => array(
                array(array('Label'  => 'Description'), array('tag' =>
'span',   'class' => 'cancel')),
                array(array('Button' => 'HtmlTag'),    array('tag' =>
'button', 'type' => 'submit', 'class' => 'cancel')),
        )));


The above gives me:


<button class="cancel" type="submit">
    <span class="cancel">Cancel</span>
</button>


So the new question is:
Is there a better way to do this (besides creating a custom element) that I
should know about?


-----
--
Wil Moore III

Why is Bottom-posting better than Top-posting:
http://www.caliburn.nl/topposting.html
-- 
View this message in context: 
http://zend-framework-community.634137.n4.nabble.com/Zend-Form-Custom-Element-PHP-5-3-tp2289497p2290467.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to