HTML_QuickForm | putting 'submit' and 'reset' in a group
| From: | Jeff MacDonald | Date: | Mon, 08 Dec 2003 23:33:12 +0000 |
| Subject: | HTML_QuickForm | putting 'submit' and 'reset' in a group | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-9390@lists.php.net to get a copy of this message | ||
greetings,
for layout purposes, I'd like to have the 'submit' and 'reset' buttons in a
group so they are displayed next to each other instead of on seperate lines.
-- snip --
$group = array();
$group[] = &HTML_QuickForm::createElement("submit", "submit",
"submit");
$group[] = &HTML_QuickForm::createElement("reset", "reset",
"reset");
$form->addGroup($group);
-- snip --
the problem is that when I click the 'reset' button, the form actually
*submits*.. is there something I need to check for in the code to trap this?
when I click reset, I expect it to 'undo' my changes, but certainly not to
submit the form.
is there an example someplace that I can look at?
regards,
J