$("table td").click(function(){ /*……*/ })
This way of writing cannot handle dynamically added "td", so it is changed to the following:
$("table").on("click","td",function(){ /*……*/ })
But now we need to deal with a special one, which does not need to include a certain one:
$("table td").not($(".check")).click(function(){ /*……*/ }),
What I want to ask now is: How to write the parameters like above and what is the format. . .
$('table').on('click','td:not(.check)',handler)
In fact, if the class name of the current element obtained in the function contains
.check
, isn’t it enough to just do a return or other processing?It’s early in the morning and I didn’t understand the meaning of the question clearly. If you don’t want to deal with td with check