Below is a demonstration of how JavaScript timeouts can be used to protect against rapid-fire requests (such as when user clicks buttons as fast as they can for fun). Try out this page now, or view it as a JSFiddle.