16 Sep
2005
16 Sep
'05
7:04 a.m.
Forms with nested groups of elements have to be navigated as keyed arrays: $form['admin']['options'] for example. When a newly loaded object is prep'd for use using object2array($object), it flattens the properties to $form['options'] and so on. if you're not expecting it,
i think array2object and object2array could be simplied like so: function array2object($arr) { return (object) $arr; } this would avoid the flattenning that you mention, as well as save some cycles. anyone care to test this and submit a patch if it works?