jquery小知识——自定义isNull

来源:互联网 发布:小米双卡网络切换 编辑:程序博客网 时间:2024/05/28 01:36
//校验必填项function check() {//用此函数来判断是否为空 处理表单的数据 if(isNull($("#merchantsName").val()) || isNull($("#merchantsCode").val())  ){alert("信息填写不完整");return false;}return true;}/** 判断知否为空  **/function isNull(s){if(s == null || s == ""){return true;}}

0 0