( , ).
, "submit".
$(this).bind("submit", function(caller){
$.validationEngine.onSubmitValid = true;
$.validationEngine.settings = settings;
if($.validationEngine.submitValidation(this,settings) == false){
if($.validationEngine.submitForm(this,settings) == true) {return false;}
}else{
settings.failure && settings.failure();
return false;
}
})
The problem is that if you have several submit event handlers attached to this form, it .unbind('submit')will kill all the events you linked to.
Assuming the event was the last connected, you can only remove the last event handler that will be dispatched:
var events = $("#myForm").data('events');
alert(events.submit.length);
events.submit.splice(events.submit.length - 1, 1);
gnarf source
share