Web Hosting Talk







View Full Version : Help? (HTML Forms)


Synthetic
07-31-2002, 04:11 PM
I am trying to get two DHTML scripts to work with my HTML form.

I am using the "submit once" and "form validation" scripts which can be fount at Dynamic Drive (http://www.dynamicdrive.com).

This is the current code I am using:

<form action="cgi-bin/formmail.cgi" method="POST" onSubmit="submitonce(this)" onsubmit="return formCheck(this);">... But it does not seem to work. Most likely because I have duplicated the onsubmit element?

Does anyone know how I can work my way around this? I've been struggling with it for quite some time now..


Validation script: http://www.dynamicdrive.com/dynamicindex16/requiredcheck.htm
Submit once script: http://www.dynamicdrive.com/dynamicindex11/submitonce.htm

ThomasT
07-31-2002, 04:34 PM
Not sure about this, but have you tried combining the two scripts into one script that first does the check, then submit(once) ?

Synthetic
07-31-2002, 04:44 PM
I just tried it, doesn't work... javascript errors occur.

MikeM
07-31-2002, 05:14 PM
try:

<form name="formcheck" onsubmit="return formCheck(this);submitonce(this);" method=post action="cgi-bin/mailscripthere" >