1//jQuery 1.6+ use:
2$("#inputID").prop('disabled', true); //disable
3$("#inputID").prop('disabled', false); //enable
4
5//jQuery 1.5 and below use:
6$("#inputID").attr('disabled','disabled'); //disable
7$("#inputID").removeAttr('disabled'); //enable
1 $('#edit').click(function(){ // click to
2 $('.inputDisabled').attr('disabled',false); // removing disabled in this class
3 });
1$('.class').prop("disabled", true);
2$('#id').prop("disabled", true);
3
4// As function
5const disable = (id) => $(`#${id}`).prop("disabled", true);