title: setTimeout only works under 1000ms
body: <p>I want to have a timeout function so when a form is submitted the alert is displayed two seconds after the submit. The code I am using doesn't work:</p>
  
  <pre><code>$(document).ready(function() {
    $("#newsletter").submit(function() {
       setTimeout(function() {
        alert("submitted");             
      }, 2000);
     });
  });
  </code></pre>
  
  <p>But when I change the 2000ms to 900 is seems to work fine:</p>
  
  <pre><code>$(document).ready(function() {
    $("#newsletter").submit(function() {
      setTimeout(function() {
       alert("submitted");              
     }, 900);
    });
  });
  </code></pre>
  
  <p>How can I get the 2000ms to work?</p>