yes that's possible. for the button use the onClick event handler to call
javascript functions. you can write a seperate function for each button the
user hits. Or you can pass a parameter to the same function which tells it
what button they pressed and depending on that with an if statement you can
validate whatever fields need to be validated.

boaz

-----Original Message-----
From: A mailing list about Java Server Pages specification and reference
[mailto:[EMAIL PROTECTED]]On Behalf Of Angela Chow
Sent: Tuesday, August 29, 2000 10:37 PM
To: [EMAIL PROTECTED]
Subject: jsp and javascript


Hi,

i have a form which have three buttons: delete item,
more line items, and verify orders.  In this form, i
have 5 rows which users can fill out 5 orders.  I have
already did the validation on each field.  I am
wondering if i can have javascript do certain
validation based on the button the user clicks on.

For example, if the user clicks on the verify order
button, i want javascript to validate all the fields
contain valid information; if the user clicks on the
more item item button, i want javascript to valid that
all the rows in the form are filled up.

please help!

Angela

__________________________________________________
Do You Yahoo!?
Yahoo! Mail - Free email you can access from anywhere!
http://mail.yahoo.com/

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to