if ($('#hy_user').val() == ""){
layer.msg('用户名不能为空');
$("#hy_user").focus();
return false;
};
if ($('#hy_user').val().length<4){
layer.msg('用户名不能小于4位数');
$("#hy_user").focus();
return false;
};
if ($('#hy_password').val() == ""){
layer.msg('密码不能为空');
$("#hy_password").focus();
return false;
};
if ($('#hy_password').val().length<6){
layer.msg('密码不能小于6位数');
$("#hy_password").focus();
return false;
};
var hy_password = $("#hy_password").val();
var hy_password2 = $("#hy_password2").val();
if(hy_password != hy_password2){
layer.msg('两次输入的密码不相同');
$("#hy_password2").focus();
return false;
}
if ($('#a_mobile').val() == ""){
layer.msg('手机号码不能为空');
$("#a_mobile").focus();
return false;
};
if ($('#a_mobile').val().length<11){
layer.msg('手机号不能小于11位');
$("#a_mobile").focus();
return false;
};
var a_mobile = $("#a_mobile").val();
if(!(/^1[3|4|5|6|7|8|9][0-9]\d{4,8}$/.test(a_mobile))){
layer.msg('手机号格式不正确');
$("#a_mobile").focus();
return false;
};
if ($('#a_company').val() == ""){
layer.msg('公司名称不能为空');
$("#a_company").focus();
return false;
};
};