Enable/Disable a dropdownbox in jquery
I am using JQuery > 1.8 and this works for me...
$('#dropDownId').attr('disabled', true);
Here is one way that I hope is easy to understand:
http://jsfiddle.net/tft4t/
$(document).ready(function() {
$("#chkdwn2").click(function() {
if ($(this).is(":checked")) {
$("#dropdown").prop("disabled", true);
} else {
$("#dropdown").prop("disabled", false);
}
});
});