我有一个子表单,我在其中设置了图例。
$dob = new Zend_Form_SubForm();
$dob->addElement($birthdayMonth)
->addElement($birthdayDay)
->setLegend('when is your birthday?');
如何设置 Legend 使其不会对文本进行转义?
通常我会得到装饰器,但这不起作用:
$decorator = $dob->getDecorator('Legend');
$decorator->setOption('escape', false);
最佳答案
您可以设置 Fieldset 装饰器,它将它传递给 Legend 字段。
$dob->getDecorator('Fieldset')
->setOption('escape', false);
关于html - 在 Zend SubForm 中,如何将 Legend escape 设置为 false?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4087681/