title: Reset Form / remove error classes from jQuery validate
body: <p>i have a contact form with jQuery validate method. When the user click on "Reset"-button the hole contact form should be go to the initial state.</p>
  
  <p>This is the button looks like:</p>
  
  <pre><code>&lt;form class="form" method="post" action="" name="contact" id="contact"&gt;
    &lt;button type="button" id="cancel" class="btn btn-danger btn-lg"&gt;Reset&lt;/button&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>And the JS-Code in my "$(document).ready-function" is:</p>
  
  <pre><code>$('#cancel').on('click', function () {
     $("#contact").validate().resetForm();
     $("#contact").removeClass("has-error");
  });
  </code></pre>
  
  <p>Problem: The error Text and the Input-fields will be deleted. But the red border (.has-error) or the green border (.has-success) don't be deleted.</p>
  
  <p>i've created an JSFiddle for you:</p>
  
  <p><a href="http://jsfiddle.net/bBc8c/1/" rel="noreferrer">http://jsfiddle.net/bBc8c/1/</a></p>
  
  <p>One Button is clear the input text, the other is delete the error Messages.
  I need a Button which reset both (Text, Error Message) and the main problem the red border from the has-* classes.</p>
  
  <p>One Button is declared as type=submit the other is type=button:</p>
  
  <pre><code>&lt;button type="button" id="cancel" class="btn btn-danger btn-lg"&gt;Reset 1&lt;/button&gt; 
  &lt;button type="reset" id="cancel2" class="btn btn-danger btn-lg"&gt;Reset 2&lt;/button&gt;
  </code></pre>