Issue 1253: Now, when the submit button is clicked, it becomes disabled for 3 seconds before it's enabled again.

git-svn-id: http://xe-core.googlecode.com/svn/branches/luminous@11135 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
nagoon97 2012-09-03 05:03:06 +00:00
parent 2a71b33df7
commit 0a473d2d63
3 changed files with 33 additions and 3 deletions

View file

@ -473,7 +473,22 @@ jQuery(function($) {
$(this).hide().prev('button').show().parent().next(fold_container).hide();
});
}
jQuery('input[type="submit"]').click(function(ev){
var $el = jQuery(ev.currentTarget);
setTimeout(function(){
return function(){
$el.attr('disabled', 'disabled');
};
}(), 0);
setTimeout(function(){
return function(){
$el.removeAttr('disabled');
};
}(), 3000);
});
});
(function(){ // String extension methods