码迷,mamicode.com
首页 > Web开发 > 详细

js获取复选框的value

时间:2017-07-16 15:42:46      阅读:138      评论:0      收藏:0      [点我收藏+]

标签:获取   nbsp   pre   function   asc   blog   javascrip   text   check   

<script type="text/javascript">
function temp(){
    var temp=document.getElementsByName(‘name‘);
    
        for(var i=0;i<temp.length;i++){
            if(temp[i].checked==true){
            alert(temp[i].value);
        }
    }
 }
</script>

 

js获取复选框的value

标签:获取   nbsp   pre   function   asc   blog   javascrip   text   check   

原文地址:http://www.cnblogs.com/miye/p/7190533.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!