Skip to main content

Posts

Showing posts with the label jquery prevent multiple form submit

JQuery Disable Button on Click To Prevent Multiple Form Submits Example

Hii Dev, In this example, i will give you simple example in jQuery disable button on click to prevent multiple form submits. we will lean how to disable button on click to prevent multiple form submits in jquery. we can stop duplicate form submission using jquery. we can easily disabled button on click event in jquery for prevent duplicate form submit. when you click on submit button than it should be disabled so it's click again. I written example for that, you can use bellow php file. you can see bellow full code. You can also check this small jquery code and full code. Jquery code $(document).ready(function () { $("#formABC").submit(function (e) { //stop submitting the form to see the disabled button effect e.preventDefault(); //disable the submit button $("#btnSubmit").attr("disabled", true); return true; }); }); Here is a full example, you can see. Full Example <!DOCTYPE html> <