title: How to stop default action of button if validation fails
body: <p>I have a multi-step form which works by hiding/showing DIV elements within a form depending on which button you clicked (<code>NEXT</code> or <code>BACK</code>).</p>
  
  <p>I'm also using JQuery Validation plugin to validate the form.</p>
  
  <p>All I want to do is have the form validated each time someone clicks on <code>NEXT</code>. Here is my JQuery so far:</p>
  
  <pre><code>$("#Next").bind("click", function(e) {
       $("#myForm").validate();      //validate the form when clicking on next
       $("#FormStepCurrent").hide(); //hide the current div
       $("#FormStepNew").show();     //show the new div
  });
  </code></pre>
  
  <p>So when someone clicks on the button NEXT it triggers the validation and should then show the next div. But if there are validation errors within the currently visible div, how do I prevent it from hiding/showing the currently visible div until the error is fixed?</p>