Rendering in QuickForm Controller
| From: | Wolfgang Annen | Date: | Thu, 25 Mar 2004 14:01:31 +0000 |
| Subject: | Rendering in QuickForm Controller | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-11503@lists.php.net to get a copy of this message | ||
I tried to customize the output in Quickform Controller with using a
renderer. I also used a subclass for QuickForm_Action_Display and put in the
function _renderForm as you can see in the code below. However, the last
command "$tpl->show();" does not output anything.
I tried the same renderer with QuickForm only and it worked without
problems. Is anybody here who can help me with this issue?
Thanks in advance
Wolfgang Annen
Here the code-snippet:
function _renderForm(&$page)
{
$tpl =& new HTML_Template_ITX('./templates');
$tpl->loadTemplateFile('bestellf1.html');
$renderer =& new HTML_QuickForm_Renderer_ITStatic($tpl);
$renderer->setRequiredTemplate('{label}<font color="red"
size="1">*</font>');
$renderer->setErrorTemplate('<font color="orange"
size="1">{error}</font><br />{html}');
$page->accept($renderer);
$tpl->show();
}