JavaScript Coder

Javascript Form Handling

jQuery disable button on click to prevent multiple form submits

The default behavior of a submit button obvious – clicking it submits the contents of a form to the server. This seems quite straightforward. So, what could possibly go wrong? Well, what if the user double clicks on the submit button rather than clicking it just the once? The contents of the form will be submitted twice. If there is no response to indicate the form was submitted, some users will click again and the form will get submitted again.

Continue Reading →