クリックするとイベントをトリガーするテーブル行があります。行内に(表示されていない)チェックボックスとそのスタイル付きラベルがあります。
私が欲しいのは、チェックボックス/ラベルがクリックされた場合に実行を防ぐことです(:notまたは.not()で推測しますが、それを理解することはできません)。
HTML:
<center>
<table>
<tr class='pend'>
<td><input type="checkbox" id="bb"/> <label for="bb">X</label></td>
<td> </td>
<td>some text</td>
</tr>
</table>
</center>
CSS:
center {
margin-top:20px;
}
input[type=checkbox] + label {
width:10px;
height:10px;
background-color:red;
}
input[type=checkbox] {
display:none;
}
table tr {
height:40px;
background-color:gray;
}
table td {
padding:5px;
}
JS:
$('.pend').on('click',function(){
$(this).append('text');
return false;
})
JSFIDDLE: http: //jsfiddle.net/ySuGB/2/