Re: Re: DB_Table QuickForm rules

From: Date: Thu, 20 Apr 2006 12:23:52 +0000
Subject: Re: Re: DB_Table QuickForm rules
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-23766@lists.php.net to get a copy of this message
On 20 Apr 2006, at 14:16, Mark Wiesemann wrote: Hi Mark
I only had a quick look at your code -- but:
$oBet =& new Bet($G_DB, 'bet', 'safe'); $G_FORM = new HTML_QuickForm('lab', 'post', '', '', '');
Instead of using the second line of the code snippet from above $G_FORM =& $oBet->getForm(null, null, array('formName' => 'lab')); should do the trick as this also calls addRules() in Table/QuickForm.php. ('post' is not specified in the $args array because DB_Table uses 'post' as the default value for the method option of QF.)
But I don't want the whole form be the same elements. Some of them I want to be grouped and there has to be a couple of other hidden input elements present in the form. So to my knowledge getForm() is not an option. Do you have another suggestion? Thnx! - Charlie

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