title: jQuery Validate plugin with custom rule remote validation not working
body: <p>I am using jQuery validate plugn for FuelUX wizard form validation. Now I need to validate a couple of fields with remote validation. As my form is in a wizard and validation needs to happen when I click on the Next button, I added a custom rule for validation as below :</p>
  
  <pre><code>    $.validator.addMethod("validateRule", function(value, element) {
  
          var validator       = this;
  
  
          $.ajax({
              url: url,
              type:"POST",
              data: data,
          })
          .done(function(valid) {
  
              if (valid == "true") {
                  return true;
              } else {
                  var errors = {};
                  errors[element.name] =  valid;
                  validator.showErrors(errors);
                  return false;
              }
  
          })},'’);
  </code></pre>
  
  <p>and my validation is called from :</p>
  
  <pre><code>    $('#create').validate({
          errorElement: 'div',
          errorClass: 'help-block',
          focusInvalid: true,
          rules: {
              field1: {
                  required: true
              },
              title: {
                  required: true,
                  validateRule:true
              },
  </code></pre>
  
  <p>When clicking on the Next button I am checking the displayed form is valid through </p>
  
  <pre><code>    $('#fuelux-wizard').ace_wizard().on('change' , function(e, info){
  
  
          if (info.direction == 'next' &amp;&amp; !$('#create').valid()) {
              return false;
          }
      }).on('finished', function(e) {
          $('#create').submit();
      }).on('stepclick', function(e){
          //return false;//prevent clicking on steps
      });
  </code></pre>
  
  <p>The problem here is that when I check $('#create').valid() it is always false irrespective of what I am getting from server. I think it is not waiting for the ajax call to complete and moving to the next line of the code. How this can be fixed ? </p>