title: how to use jquery to change background color of textbox for 3 seconds?
body: <p>I'm doing a textbox and if the requirements does not meet then the background will change to yellow but I only want the background to stay yellow for 3 seconds....how can I do that?</p>
  
  <p>This is what I have at the moment but the yellow bg stays...</p>
  
  <pre><code>$("#form").on("submit",function(){
  
  
  user = $("#username").val().length;
  userErrorBg = $('#username').css('background','yellow');
  
  
  if(user &lt; 3 || user &gt; 6)
  {
  
      setInterval("userErrorBg",0);
  
  }
  
  })
  </code></pre>
  
  <p>I'm thinking of putting a clearInterval somewhere but I will need a time count right?</p>