Jquery选择根节点时,勾选子级前的复选框

适用情况,DIV 布局的树
$(function(){
//给复选框注册单击事件
$('#webfx:checkbox').click(function(){
$(this).parent().next().find(":checkbox").attr("checked",this.checked);
});
});

猜你喜欢

转载自helloworlda.iteye.com/blog/1199412