为了账号安全,请及时绑定邮箱和手机立即绑定

为啥没反应啊

<!DOCTYPE html>

<html>

<head>

<meta charset="utf-8" content="text/html">

<script src = "D:\mycode\jquery-3.2.1.js"></script>

<script src = "D:\mycode\jquery.validate-1.13.1.js"></script>

<link rel="stylesheet" type="text/css" href="css/validform.css">

<title>validation Demo</title>

</head>

<body>

<form id = "form1">

<fieldset>

<legend>用户登录</legend>

<p>

<LABEL for = "username">用户名</LABEL>

<input type="text" name="username" id="username">

</p>


<p>

<LABEL for = "password">密码</LABEL>

<input type="text" name="password" id="password">

</p>


<p>

<input type="submit" value="登录">

</p>

</fieldset>

</form>


<script type = "text/javascript">

$(document).ready(function(){

alter("sadd");

$("#form1").validate({

rules:{

username:{

required:true,

minilength:2,

maxlength:10

},

password:{

required:true,

minilength:2,

maxlength:10

}

}

});

});

</script>

</body>

</html>


正在回答

2 回答

找到问题了,alter那句错了,删了就行了。

2 回复 有任何疑惑可以回复我~

<meta charset="utf-8" content="text/html">

<script src = "D:\mycode\jquery-3.2.1.js"></script>

<script src = "D:\mycode\jquery.validate-1.13.1.js"></script>

<link rel="stylesheet" type="text/css" href="css/validform.css">

这几行代码有错误

1 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

为啥没反应啊

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信