I'm new with developing in Zend Framework. I did some research about form decorators but i want some specific stuff.
This is what i want:
<table>
<tr>
<td colspan="2">
<ul class="errors">
<li>error</li>
</ul>
</td>
</tr>
<tr>
<td>Label :</td>
<td>input field</td>
</tr>
<tr>
<td></td>
<td>Submit Button</td>
</tr>
</table>
What i've got is:
$this->setElementDecorators(array(
'ViewHelper',
array(array('data' => 'HtmlTag'), array('tag' => 'td', 'class' => 'element')),
array('Label', array('tag' => 'td')),
array(array('row' => 'HtmlTag'), array('tag' => 'tr'))
));
$submit->setDecorators(array('ViewHelper',
array(array('data' => 'HtmlTag'), array('tag' => 'td', 'class' => 'element')),
array(array('emptyrow' => 'HtmlTag'), array('tag' => 'td', 'class' => 'element', 'placement' => 'PREPEND')),
array(array('row' => 'HtmlTag'), array('tag' => 'tr'))
));
$this->setDecorators(array(
'FormElements',
'Errors'
array('HtmlTag', array('tag' => 'table')),
'Form'
));
but it comes with an htmlspecialchar warning, and the ul is empty.
is there any possibility to fix this?