📜  禁用选项下拉 jquery - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:57.746000             🧑  作者: Mango

代码示例1
//disable by value
$("#ddlList option[value='jquery']").attr("disabled","disabled");

//disable by text
$('#ddlList option:contains("HTML")').attr("disabled","disabled");