$(function (){
$("tr").click(function () {
if($(this).children().first().children().attr("checked")=="checked"){
$(this).children().first().children().removeAttr("checked")
}else{
$(this).children().first().children().attr('checked',true);
}
});
});
这段代码 在第一次加载页面的时候 点击TR 范围内是好使的 可以选择上 再次点击也可以取消选择 但是只能执行一次 在点击的时候虽然也在判断执行 可是页面是没有反应的没有 选择上