RE: [PEAR] javascript processing HTML_Quickform
| From: | Mark Steudel | Date: | Mon, 14 Nov 2005 22:31:22 +0000 |
| Subject: | RE: [PEAR] javascript processing HTML_Quickform | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-21923@lists.php.net to get a copy of this message | ||
If I understand you correctly you want to add javascript functions to
different elements in QuickForm, such as using onsubmit() or onclick() etc?
This is from the documentation:
http://pear.php.net/manual/en/package.html.html-quickform.html-quickform.htm
l-quickform.php
HTML_QuickForm::HTML_QuickForm ([string $formName = '' [, string $method =
'post' [, string $action = '' [, string $target = '_self' [, mixed
$attributes = NULL [, bool $trackSubmit = FALSE]]]]]])
See the mixed attributes above, you can add your additional stuff there:
Exampl:
$nominationForm = new HTML_QuickForm('nominationForm', 'post',
$_SERVER['PHP_SELF']."?".$_SERVER[argv][0],
array('onsubmit'=>'process();')
);
Hope that's what you were asking.
Mark
>-----Original Message-----
>From: Antonio Luis Batista [mailto:albatista@gmail.com]
>Sent: Monday, November 14, 2005 1:32 AM
>To: pear-general@lists.php.net
>Subject: [PEAR] javascript processing HTML_Quickform
>
>Hi all, I have been using HTML_Quickform for a while but I
>need to do something that I'm not sure is possible.
>The matter is that I want a javascript method to process the
>form, you know something like putting onrequest in the submit
>button, is this possible, can you give me some hints in this??
>Thanks in advance.
>
>--
>PEAR General Mailing List (http://pear.php.net/) To
>unsubscribe, visit: http://www.php.net/unsub.php
>
>