My code is as simple as like this
$(document).ready(function(){
$('#somebutton').click(function(){
$('#someformid').submit();
return false;
});
});
During this form submit ,normally the page will wait for 1 or 2 sec for the load ,in this mean time user can click the ‘somebutton’ again and the form will submit again.My question is how do i lock the browser or disable form submit if a form submit process is going on ?
P.S somebutton is an image
You could use .one, which make the handler execute at most once.