Zend Form problem:Setting decorators for textarea and textinput length values
- by davykiash
In my Zend form code I have the following
$address = new Zend_Form_Element_Textarea('accounts_address');
$address->setLabel('Address')
->setAttrib('rows','4')
->setAttrib('cols','4')
->addFilter('StripTags')
->addFilter('StringTrim')
->addValidator('NotEmpty');
$address->setDecorators(array(
'ViewHelper',
'Description',
'Errors',
array(array('data'=>'HtmlTag'), array('tag' => 'td')),
array('Label', array('tag' => 'td')),
array(array('row'=>'HtmlTag'),array('tag'=>'tr'))
));
However in my output I do get the attributes set but the text area seems to remain the same size
Output
<tr><td id="accounts_address-label"><label for="accounts_address" class="optional">Address</label></td>
<td>
<textarea name="accounts_address" id="accounts_address" rows="4" cols="4"></textarea></td></tr>
What am I missing?