Home  >  Article  >  php教程  >  jquery determines whether checkbox is empty

jquery determines whether checkbox is empty

WBOY
WBOYOriginal
2016-08-04 08:53:361311browse
跳至 [1] [全屏预览]
        //导出excel数据
        $("#export").click(function () {

                 if($(".list input[name='stuid[]']:checked").size()==0){    
                alert("请先勾选学生信息,再做导出操作!");   
                return false;   
            } else {
                $(".sendform").attr({action: "./export.php?do=export", method: "post"});
                $('.sendform').submit();
            }

        });
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn