Intente usar el addElementPrefixPath y tampoco me funcionó
Código PHP:
Ver original<?php
class Reports_Form_Foo extends Zend_Form
{
public function init()
{
$n=1;
// initialize form
$this->setMethod('post')
->addElementPrefixPath('Reports_Model', 'reports/models/',
Zend_Form_Element::VALIDATE)
->setAttrib('accept-charset', 'utf-8')
->setDecorators(
'FormElements',
'Form',
)
);
// create select input for foo
$foo = new Zend_Form_Element_Select('foo');
$foo->setLabel('Foo:')
->setDecorators(
'Errors',
'ViewHelper',
)
)
->addValidator('ExtraValidate')
->setOptions(array('tabindex'=>$n++)); ''=>'[Selecciona uno]',
1=>'Foo',
2=>'Bar'
),
3=>'Baz',
4=>'Candy',
5=>'Fruits'
),
);
$foo->addMultiOptions($fooArray);
// create submit button
$submit = new Zend_Form_Element_Submit('submit');
$submit->setLabel('Submit')
->setOptions(array('class' => 'submit', 'tabindex'=>$n++)) ->setDecorators(
'ViewHelper',
)
);
$this->addElements(
$foo,
$submit
)
);
}
}
Hace nada