title: question with jquery validation
body: <p>I am trying to attach the validation on a button click. I have: </p>
  
  <pre><code>  &lt;script&gt;
   $().ready(function() {
  //
      $("#btnAdd").click(function() { 
  
          $("#myForm").validate({                     
          // $("#crap").rules("add", {required: true,  messages: {required:"Required input"} });
          rules: { crap: "required" },
          messages: { crap: "required field"}
          // $("#myForm").validate();
          });   
  
  });
  
  }); 
  &lt;/script&gt;
  
  &lt;form method="post" id="myForm" name="myForm"&gt;
  &lt;input type="text" name="crap" id="crap" class="required" /&gt;
  &lt;br /&gt;
  &lt;input type="button" name="btnAdd" id="btnAdd" value="add" /&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>now, if i change btnAdd to a submit type, it works. otherwise, it won't. how can i call the validation on a button click ? thanks</p>