<style type="text/css">
*{
margin: 0;
padding: 0;
}
span {
color: red;
font-size: 12px;
}
body {
background-color: antiquewhite;
}
form {
width: 300px;
height: 600px;
margin: 100px auto;
}
</style>
</head>
<body>
<form
id="userForm"
action="http://localhost:8080/js program/表单验证"
method="get">
<b>XXXX宿舍水电管理系统注册</b>
<br /><br />
用户名:<input type="text" name="username" id="username" />
<br>
<span id="usernameError" style="color: red;"></span>
<span id="usernameRight" style="color: green;"></span>
<br />
密码:<input type="text" name="userpwd" id="userpwd" />
</br>
<span id="pwdError" style="color: red;"></span>
<span id="pwdRight" style="color: green;"></span>
<br />
确认密码:<input type="text" id="userpwd2" />
JS用户注册案例
最新推荐文章于 2024-04-26 17:21:31 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)