JQuery.Validation, ajax sumbit with captcha??

JQuery.Validation, ajax sumbit with captcha??

Hello I use ajax submit for my jquery validation form.  I NEED a captcha for the form, being I am getting attacked by bots.  I cannot figure out how to do it.  I will past my code below.


  1. $('#contact_form2').validate({
  2. submitHandler: function(form) {
  3. var str = $("form").serialize();
  4. $.ajax({
  5. type: "POST",
  6. url: "contactpage.php",
  7. data: str,
  8. success: function(){
  9.         $('#contact_form2').html("<div id='message'></div>");
  10.         $('#message').html("<h2>Contact Form Submitted!</h2>")
  11.         .append("<p>We will be in touch soon.</p>")
  12.         .hide()
  13.         .fadeIn(1500, function() {
  14.           $('#message').append("<img id='checkmark' src='images/check.png' />");
  15.         });
  16.       }});
  17. return false;
  18. }


I would very much appreciate the help! Thank you!

-Dave