I have an ajax method that fires on the keyup event, but I don’t really want it to fire instantly, every single time the user presses a key – ideally I’d like to give a 1-2 second delay before going off to the server, so if the user presses a key every 1/2 second, there will only be 1 call to the server when they finish typing (after 1-2 seconds of not typing anything).
How can I achieve this using jQuery?
1 Answer