RegisterRegister    SearchSearch   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

AJAX upload progress bar

File sharing script

File mirror script

Newsletter script
Form validation on submission

 
Post new topic   Reply to topic    SibSoft Ltd Forum Index -> XUpload
View previous topic :: View next topic  
Author Message
nodak



Joined: 13 Apr 2007
Posts: 14
Location: Fargo, ND

PostPosted: Apr 13, 2007 7:10 pm    Post subject: Form validation on submission Reply with quote

I have built a very customized app for our users and have integrated the xupload script to help with the file uploading.

Everything is working great, except I need to call a javascript I wrote to check the additional fields I'm gathering data from for valid info prior to submitting it for upload.

Since xupload uses the onsubmit call looking for a returned value, I wrote another function to submit the form, first calling my validation script and if it passes, then call the upload script.

Unfortunately it won't execute the upload. I'm looking for some ideas on how to make this work.

The function I'm using to submit the form is:

Code:
<script type="text/javascript" language="JavaScript">
<!--
function OnSubmitCheck() {
var formValid = Validate();
if(formValid == false) {
   return false;
}
else {
   StartUpload(this);
}
return true;
}
//-->
</script>


Looking forward to hearing some suggestions. I'm using the pro version of xupload and running on IIS6.

I'm very impressed with the script so far, you've done great work with it. I'm using it to gather data and upload image files through a PHP script and then resize the image files on the server, rename them, AND overlay text from the form.

Without this script I'd still be banging my head against the wall looking for a way for our users to track the file upload progress! Razz
Back to top
View user's profile Send private message Visit poster's website
nodak



Joined: 13 Apr 2007
Posts: 14
Location: Fargo, ND

PostPosted: Apr 13, 2007 9:10 pm    Post subject: Reply with quote

Well I got it. So no worries!

Thanks again for an excellent script!

Forgot that this means, the form being submitted and changed it to the form name.
Back to top
View user's profile Send private message Visit poster's website
PilgrimX182



Joined: 22 Mar 2006
Posts: 2106
Location: UFO Lab

PostPosted: Apr 16, 2007 9:26 am    Post subject: Reply with quote

No problems, good luck there Wink
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    SibSoft Ltd Forum Index -> XUpload All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB © 2001, 2005 phpBB Group