PEAR:HTML_QuickForm : radio element
| From: | Daniel Demacek | Date: | Wed, 01 Oct 2003 14:25:27 +0000 |
| Subject: | PEAR:HTML_QuickForm : radio element | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-8180@lists.php.net to get a copy of this message | ||
Hello,
I'm trying to add 'checked' to the first radio element any ideas on how
to do that?
I've noticed there is setSelected() but can't figure out how to use it.
$memb=array();
$memb[] = &HTML_QuickForm::createElement('radio', null, null, 'YES',
'1');
$memb[] = &HTML_QuickForm::createElement('radio', null, null, 'NO',
'0');
$form->addGroup($memb, 'cookie', 'Would you like a cookie?:',
'<br
/>');
Thanks. Dan.