title: How to clear FORM after SUBMIT AJAX
body: <p>I've tried what everyone has been saying for this but i am un able to get the form to reset after it has submitted. Everything else works except this part. Just want the form to re-set again after it all runs. Thank you!</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>&lt;script&gt;
  $("#contactForm").submit(function(e) {
   e.preventDefault();
   var Name = $("#Name").val();
   var Phone = $("#Phone").val();
   var Company = $("#Company").val();
   var Website = $("#Website").val();
   var Service = $("#Service").val();
   var Message = $("#Message").val();
   var myData ={"Name":Name,"Phone":Phone,"Company":Company,"Website":Website,"Service":Service,"Message":Message}
   if(Name == "" || Phone == "" || Company == "" || Website == "" || Service == "" || Message == "" ) {
    $("#error_message").show().html("All Fields are Required");
   } else {
    $("#error_message").html("").hide();
    $.ajax({
     type: "POST",
     url: "submitAjax.php",
     data: myData,
     success: function(data){
      $("#contactForm").reset();
      $('#success_message').fadeIn().html(data);
      setTimeout(function() {
       $('#success_message').fadeOut("slow");
      }, 2000 );
      
  
     }
    });
   }
  })
  &lt;/script&gt;</code></pre>
  </div>
  </div>
  </p>