标签:
var str=document.getElementsByName("joined"); var objarray=str.length; var chestr=""; for (i=0;i<objarray;i++) { if(str[i].checked == true) { chestr+=str[i].value+","; } }
选取复选框的id值,以逗号分割
原文地址:http://www.cnblogs.com/cxyzh/p/5915701.html