jquery:
<div id="divId" class="divTable"><div class="tableBody"><ul ><li ><input type="checkbox" value="501" ></li></ul></div></div>
$("input[type='checkbox']").attr('value')返回结果:501$("input[type='checkbox']").is(':checked')返回结果:选中=true,未选中=false
js:
if(document.getElementById("checkboxID").checked){ alert("checkbox is checked");}
转载于:https://www.cnblogs.com/quanfu2326/p/4600314.html