代码
<script type="text/javascript">
//<![CDATA[
jQuery(document).ready(function(){
var j = jQuery("input[name='diagnostic[]']").length;
jQuery("input[name='diagnostic[]']").each(function(e){
if(jQuery(this).attr("checked") == false)
j--;
});
});
//Pay attention to the code marked with red color. After that, we can get that at least one checkbox is selected.
//]]>
</script>