8
Hi I have setup an autocomplete input text. I am trying to fire the event of reprinting the table on click of a btn and on a enter keypress. the btn click works fine and but the enter key press seems like it fires a few times before stoping (meaning the table flickers)
$('body').bind('keypress', function(e) {
if(e.keyCode==13){
var str = $('#Filter').val();
$('#Table').fadeOut("slow").load('printShorts.server.php?Sortby=<?echo $sort;?>&dir=<?echo $direction;?>&filter='+encodeURIComponent(str)+'&usergroup=<?=$usergroup?>&no-cache=' + (new Date()).getTime() ).fadeIn("slow");
}
});
it doesn't happen all the time and acts differntly in differnt browsers..