I have a button as such:
Within jQuery I am using the following, but it still
"Easy Peasy"
$(function() {
$('.targetClass').dblclick(false);
});
just put this method in your forms then it will handle double-click or more clicks in once. once request send it will not allow sending again and again request.
<script type="text/javascript">
$(document).ready(function(){
$("form").submit(function() {
$(this).submit(function() {
return false;
});
return true;
});
});
</script>
it will help you for sure.
What I found out was old but working solution on modern browsers. Works for not toggling classes on the double click.
$('*').click(function(event) {
if(!event.detail || event.detail==1){//activate on first click only to avoid hiding again on double clicks
// Toggle classes and do functions here
$(this).slideToggle();
}
});