`

js获取多拉框值

 
阅读更多
function selectValue(){
        var selectVal = document.getElementById("vipLev");
        var value="";
        for(var i=0;i<selectVal.options.length;i++){
            if(selectVal.options[i].selected){               
                value+= selectVal.options[i].value+";";
            }
        }
        value = value.substring(0, value.length -1);
          alert(value);
}
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics