QuickForm Renderer Question

From: Date: Mon, 01 Mar 2004 14:35:47 +0000
Subject: QuickForm Renderer Question
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-11030@lists.php.net to get a copy of this message
Hi Guys I am creating a form with HTML_Quickform 3.2.1 and customising the default renderer to get the look and feel I want. How do I pass an array of information to a header tag for my custom template to render the header title and a description? Here is a sample of the relevant code, which displays Array {header_2} when executed. $form->addElement('header', 'header_company', array('Company Details', 'short description')); $header_template = '<tr> <td style=\"white-space:nowrap;background:#F5E004;color:#000000;\" align=\"left\" colspan=\"2\"> <b>{header} <!-- BEGIN header_2 --><br /><span style="font-size: 80%;">{header_2}</span><!-- END header_2 --></b> </td> </tr>'; $renderer =& $form->defaultRenderer(); $renderer->setHeaderTemplate($header_template); $form->accept($renderer); $form->display(); What am I doing wrong? Many Thanks Alex

« previous php.pear.general (#11030) next »