View Single Post
Old 03-10-2004, 09:36 PM  
grannytgp
Confirmed User
 
Join Date: Aug 2002
Posts: 269
java-script help - AutoGallery submit form

I'm looking to implement the Filthbot "Description Length Validator" script into my AutoGallery SQL submit form. I actually have the code inserted into the form page, and have it working just fine -- but have one problem.

The new version of AutoGallery uses java-script of its own to validate the email/gallery URL/# of thumbs. So within the POST method code, autogallery uses an "onSubmit" handler to run the validation script before the form is posted.

Now with the addition of the Description Length Validator, I have to add another handler to the POST method line -- only problem is, I can't get two "onSubmit" handlers to work properly.

I know there are basically two ways around this:

1. Combine both validation scripts into one script, and then I would only need one handler.
2. Figure this bugger out to use two "onSubmit" handlers - which is what I've been trying to do unsuccessfully so far

Here are some I've tried so far without success:

PHP Code:
onsubmit="return (checkForm(this) && return Desc_Validator());">
onsubmit="return Desc_Validator();return checkForm(this);">
onsubmit="return checkForm(this) & return Desc_Validator();">
onsubmit="return checkForm(this) && return Desc_Validator();"
Any help on this one would be greatly appreciated.
__________________
No sig = good sig

Last edited by grannytgp; 03-10-2004 at 09:46 PM..
grannytgp is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote