Disable / Re-enable Inputs
Disable:
$("#submit-button").attr("disabled", true);
Re-enable:
$("#submit-button").removeAttr("disabled");
Disable:
$("#submit-button").attr("disabled", true);
Re-enable:
$("#submit-button").removeAttr("disabled");
You can also use the
.prop()function.A simple
$("#submit-button").prop('disabled', true);
$("#submit-button").prop('disabled', false);
will also do then.
.prop does not work in IE
Yes Its Not Workin On Internate Explorer
Which version? I am using it in this tutorial jquery disable button and it is working fine in IE9, do you mean earlier versions, I didn’t know this.
Thanks!
yeahh…