submitHandler is an invalid label
Posted
by Steven
on Stack Overflow
See other posts from Stack Overflow
or by Steven
Published on 2010-01-27T03:20:31Z
Indexed on
2010/05/15
9:54 UTC
Read the original article
Hit count: 232
Below is the code, I get an error which says that submitHandler
is an invalid label
$(document).ready(function() {
$("#withdraw").validate({
rules: {
amount: {
required: true,
number:true,
min:0,
max:<?php echo $balance; ?>
} ,
bank:{
required:true,
},
cardnumber1: {
required: true,
minlength:8
},
cardnumber2:{
required:true,
equalTo: "#cardnumber1"
},
holder:{
required:true,
}
}
}),
submitHandler: function(form){
var answer = confirm("Do you really want to withdraw this amount of money from your account?")
if (answer){
form.submit();
}
else{
return false;
}
}
});
How to solve this problem?
© Stack Overflow or respective owner