PEAR is discontinued

This is a static archive preserving historical releases and metadata. No new packages or updates will be published. For updates to existing packages, or to publish new packages, please use Composer and Packagist.

Home » HTML » HTML_QuickForm » Bug #4134

HTML_QuickForm_Renderer_ArraySmarty bug

Details

Submitted2005-04-13 08:21 UTC
Fromvirakochi at gmail dot com
StatusWont fix
PackageHTML_QuickForm
PHP Version4.3.10
OSFreeBSD 4.11
Roadmaps(Not assigned)

Comments

[2005-04-13 08:21 UTC] virakochi at gmail dot com

Description:
------------
HTML_QuickForm version 3.2
HTML_QuickForm_Renderer_ArraySmarty throws notice when trying to create group of radiobuttons named 'type'. With other names works correct.

Reproduce code:
---------------
$radio1 = HTML_QuickForm :: createElement('radio', 'type', null, 'HTML', 'html');
$radio2 = HTML_QuickForm :: createElement('radio', 'type', null, 'Plain Text', 'text');

$group = new HTML_QuickForm_group('rb', null, array($radio1, $radio2), null, false);
$form->addElement($group);
$renderer =& new HTML_QuickForm_Renderer_ArraySmarty($smarty);
$form->accept($renderer);
$smarty->assign('form', $renderer->toArray());

Expected result:
----------------
Obtain $form.rb array in smarty template

Actual result:
--------------
Got notice:
Notice: Array to string conversion in /.../pear/HTML/QuickForm/Renderer/ArraySmarty.php(241) : eval()'d code on line 1