I believe you should be able to call multiple functions by separating them
with a semicolon.
See if this works...
<input type = "submit" name = "submit" value = "Submit Form" onClick
"return validateFirstName();return validateLastName();return
validateStreetAddress()">
Roger
-----Original Message-----
From: Christopher Koniges And Lynn Horn [mailto:chris@j...]
Sent: Monday, March 12, 2001 12:47 PM
To: javascript
Subject: [javascript] RE: onSubmit Validation
Hi,
I find that the best approach is on the on submit of the form where a true
return allows the submit and a false return stops it as follows:
<form ID="frmDisplayCalendar" method="GET" target="CalendarDisplay"
action="CalendarDemo.asp" OnSubmit = "return ProcessSubmit(this)">
Good Luck,
Christopher Koniges
Database/WEB Systems Programmer
Tel: (xxx) xxx-xxxx
www.jazzysystems.com
-----Original Message-----
From: Howard Stone [mailto:zzzing@a...]
Sent: Monday, March 12, 2001 12:03 AM
To: javascript
Subject: [javascript] onSubmit Validation
I need some help on a form I am making. The form is for someone buying
online and I need to validate so that the form is not submitted with
missing info.
The form contains: name and address, cerdit card info, etc. I did the
calidation using the onBlur() method at each text field but someone
suggested that would lock the end user to fill in the form from beginning
to end. The person suggested I validate when the form is submitted so the
end user can fill it in in any order.
I like that idea but it does not seem to be working when I write:
<input type = "submit" name = "submit" value = "Submit Form" onClick
"return validateFirstName()" onClick = "return validateLastName()" onClick
= "return validateStreetAddress()">
I have written the various functions in the head of the document.
It does not seem to be working with more than one onClick function call.
Could someone assist me how to do this.
Thank you most sincerely