<script>
function create() {
if (verifycontent()) {
alert("验证通过");
}
}
function verifycontent() {
var accname = $("#accname").val();
var accpwd = $("#accpwd").val();
var accpwdcomfirm = $("#accpwdcomfirm").val();
if (accname == "" || accname == null || accname == undefined) {
alert("请输入账户名称");
$("#accname").focus();
return false;
}
if (accname.trim() == "") {
alert("账户名称不能全为空格");
$("#accname").val("");
$("#accname").focus();
return false;
}
if (accpwd == "" || accpwd == null || accpwd == undefined) {
alert("请输入账户密码");
$("#accpwd").focus();
return false;
}
if (accpwd.trim() == "") {
alert("密码不能全为空格");
$("#accpwd").val("");
$("#accpwd").focus();
return false;
}
if (accpwdcomfirm == "" || accpwdcomfirm == null || accpwdcomfirm == undefined) {
alert("请再次输入密码");
$("#accpwdcomfirm").focus();
return false;
}
if (accpwdcomfirm != accpwd) {
alert("两次输入密码不一致");
return false;
}
return true;
}
</script>