我有一个包含的 div ,我编写了7 checkboxes以下代码以访问only the checked checkboxarray icons
var icons = $("div").find("input[type=checkbox]").each(function () {
if($(this).attr("checked") == "checked") return this; });
alert(icons.length);
但它总是提醒 7 。有人能告诉我问题吗?