How to check whether Submit Button is disabled in JQuery ?
if($('#submitButton').is(':disabled')){
//Code to be executed
}
How to Enable button in Jquery ?
$('#submitButton').attr("disabled", false);
How to Disable button in Jquery ?
$('#submitButton').attr("disabled", true);
How to change value of Submit button in Jquery ?
$('#submitButton').val('Please wait ... Processing');
Code :
$('#submitButton').click(function() {
if($('#submitButton').is(':disabled'))
{
$('#submitButton').attr("disabled", false);
$('#submitButton').val('Submit');
}
else
{
$('#submitButton').attr("disabled", true);
$('#submitButton').val('Please wait ... Processing');
}
No comments:
Post a Comment