From: Christian Weiske on
Hi Alexey,

> Before we go on implementing proxies and stuff, I'd like to
> understand what is the benefit of accessing renderer rather than the
> result renderer returns?
> e.g.
> $form->render($renderer);
> echo $renderer['foo'];
> vs
> $result = $form->render($renderer)->toArray();
> echo $result['foo'];
> ?

Benefit for me is that I do not have to call toArray() :)
No, the main reason against the array renderer was that the generated
array does not allow access to the elements by their ID.
It only has a number-based index that does not help anyone.

$ar = $form->render(new HTML_QuickForm2_Renderer_Array())->toArray();

That's what bit me here. Since I needed to hack my own renderer because
of that problem, I wanted to do it right - without creating an array
that contains information which is not used in 50% of my cases.

Regards/Mit freundlichen Grüßen
Christian Weiske

-=≡ Geeking around in the name of science since 1982 ≡=-