PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » HTML » HTML_QuickForm » Bug #5793

Issue with Flexy renderer and elementnames with [] appended to it

Details

Submitted2005-10-27 11:13 UTC
Fromspam at electroteque dot org
StatusWont fix
PackageHTML_QuickForm
PHP Version5.1.0
OSn/a
Roadmaps(Not assigned)

Comments

[2005-10-27 11:13 UTC] spam at electroteque dot org

Description:
------------
I get this when i try to create elements with []
appended to them

Fatal error: Cannot access empty property in /Volumes/
DATA/www/musictrade/classes/PEAR/HTML/QuickForm/
Renderer/ObjectFlexy.php(193) : eval()'d code on line 1

in here

function _storeObject($elObj)
{
if ($elObj) {
$keys = $elObj->keys;
unset($elObj->keys);
if(is_object($this->_currentGroup) &&
('group' != $elObj->type)) {
$code = '$this->_currentGroup' . $keys .
' = $elObj;';
} else {
$code = '$this->_obj' . $keys . ' =
$elObj;';
}

eval($code);
}
}

it shows up as

->{'title'}->{''}

i have to explicity add it like [0] which is a pain
especially when i am dynamically adding the same
elements more than once for obvious uses.

What do i do ?