Hi,
I have some problems in "translating" the decorator definitions for a
table based form layout when using an ini file.
For the elements I want to use these definitions:
$this->setElementDecorators(
array(
'ViewHelper',
'Errors',
array(
array('data' => 'HtmlTag'),
array('tag' => 'td', 'class' => 'element')
),
array(
'Label',
array('tag' => 'td')
),
array(
array('row' => 'HtmlTag'),
array('tag' => 'tr')
)
)
);
This works perfectly as expected. But now I want to use the same
definitions within an ini file and I fail:
elementDecorators.helper.decorator = viewHelper
elementDecorators.errors.decorator = errors
elementDecorators.data.decorator = htmlTag
elementDecorators.data.options.tag = td
elementDecorators.data.options.class = element
elementDecorators.label.decorator = label
elementDecorators.label.tag = td
elementDecorators.row.decorator = htmlTag
elementDecorators.row.options.tag = tr
This results in an output like this:
<table class="myform">
<label for="name" class="required">Pizzaname</label>
<tr>
<input type="text" name="name" id="name" value="" size="32"
maxlength="64"></tr>
<label for="description" class="required">Beschreibung</label>
<tr>
<textarea name="description" id="description" cols="32"
rows="3"></textarea></tr>
</table>
Somehow the TD tags are missing completely and the LABEL tag is not
included within the TR tag. What is wrong with my element decorator
definitions?
Thanks for your help
Ralf