How to check a value in a textbox and if it hasn't changed for 3 seconds do something, otherwise check again in 3 seconds?
<p>This is my attempt but I believe 'checker(thisVal)' is the part which is causing problems.</p>

<pre><code>  $("#search-input").keyup(function () {
        var thisVal = $(this).val();
        if(thisVal!=''){

            var checker = function (v){
                if($(this).val() !=v){
                    setTimeout('checker(thisVal)', 3000);
                }
                else{
                    console.log($(this).val());
                }
            }
            setTimeout(function(){checker(thisVal)}, 3000);

        }
    });
</code></pre>

<p>Thanks.</p>
