<script>
$(function() {
$('#button_all_yes').click(function() {
$("#myform").find("input:checkbox").prop("checked", true);
});
$('#button_all_no').click(function() {
$("#myform").find("input:checkbox").prop("checked", false);
});
});
</script>
站內搜尋
Sunday, July 21, 2013
[jQuery] 輕鬆做出 checkbox 的 "全選" 與 "全不選" 功能
直接看程式碼:
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment