How to make jQuery wait after event
<p>I have some text boxes that uses AJAX and will process what the user types as they're typing. The problem is that the process that happens after they type is a pretty loaded one. Is there anyway that I can make the event wait 500 msec or so before it will process the event again? So let's say I type <code>a</code>, and then 200ms after I type <code>bsdke</code>. The event will only process <code>a</code> coming in. Let's say I then type <code>asdf</code> 600ms after I typed <code>a</code>. The event will then trigger and process <code>absdkeasdf</code> because it has been 500ms after the last process. </p>

<p>Or even, is there a way I can make the event not become triggered until the previous event that was triggered has finished what it was doing?</p>

<p>Is it possible? Surely sticking a timeout function at the end isn't going to work, right?</p>

<pre><code> $('#selection1-3-4-a, #selection1-3-4-b, #selection1-3-4-c, #selection1-3-4-d, #selection1-3-4-e, #selection1-3-4-f').on('input', function (e) {
    var url = "/ex.php";
    $.ajax ({
    //......

 });
</code></pre>