我想使用未包含在Zend Framework中的Dijit元素。但我不知道应该怎么做:
$subPrice = new Zend_Dojo_Form_SubForm('priceTab');
$subPrice->setLegend('Tarification :');
$sign = new Zend_Dojo_Form_Decorator_DijitElement('sign');
$sign->setDijitParams(array('dojoType' => 'dijit.form.ToggleButton',
'label' => '-',
'showLabel' => true,
'checked' => true,
'onChange' => 'toggleLabel(val)'
));
$subPrice->addElement($sign);
在我看来,我刚刚在javascript中添加了dojo.require("dijit.form.Button");
但是我从addElement
函数中收到此错误消息:
Fatal error: Call to a member function getOrder() on a non-object in D:\www\tuto\library\Zend\Form.php on line 1055
非常感谢任何帮助。
谢谢!