Reputation: 5182
I have a zend form with some element on, including a check box. It looks normal :
checkbox label []
I would like to add a link to the right making it look like this:
checkbox label [] thelink
I've tried the following, but instead of aligning horizontaly the description with the checkbox it puts it under it :
$boolean->setDescription('desc');
$boolean->setDecorators(array(
'ViewHelper',
'Description',
'Errors',
array('HtmlTag', array('tag' => 'dd')),
array('Label', array('tag' => 'dt')),
));
I'm a begginer with Zend Forms. Any idea how could i implement this?
Thank you
Upvotes: 1
Views: 408
Reputation: 5182
Got it!
Here's how i did it:
$boolean->setDescription('description');
$boolean->setDecorators(array(
'ViewHelper',
'Description',
'Errors',
array('HtmlTag', array('tag' => 'dd')),
array('Label', array('tag' => 'dt')),
array('Description', array('escape' => false, 'tag' => '', 'placement' => 'append')),
));
Upvotes: 2