validate onsubmit help

validate onsubmit help

Hi Guys,

im using the validate plugin with the metadata plugin as below :

jQuery(document).ready(
function(){
jQuery("#com-createForm").validate({ meta: "rules" } );
});


However i want to basically call this when the form is submitted becuase the form processing take along time (pdf generation):

document.getElementById('generatebutton').innerHTML='<center><b>processing</b></center>';

does anyone know how i would do this (using the validate and metadata plugin)


PS i only want to show that message if the form is submitted (ie there is no error messages)


Tnx
Sean