I have this in JQuery:
$("form").validate({ rules: {
captcha: {
required: true,
remote: {
url: "gb_include/captcha.php",
type: "post"
},
}
},
messages: {
captcha: "Correct captcha is required."
}});
$("form").submit(function(){
if($(this).valid() == true){ /* submit via ajax */ }
But I have to us .live()
because the form is loaded after $(document).ready()
how can i do that ?