禁用文本框
//文本框禁用
$("input[type='text']").each(function () {
$("#" + this.id).attr("disabled", true);
});
启用文本框
//文本框启用
$("input[type='text']").each(function () {
$("#" + this.id).removeAttr("disabled");
});
禁用文本框
//文本框禁用
$("input[type='text']").each(function () {
$("#" + this.id).attr("disabled", true);
});
启用文本框
//文本框启用
$("input[type='text']").each(function () {
$("#" + this.id).removeAttr("disabled");
});
转载于:https://www.cnblogs.com/lengzhan/p/6134295.html