<%@ page language="java" contentType="text/html; charset=utf-8"
pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
</head>
<body>
<form name="form2" action="sign_in_save.jsp" method="post">
<table width="410" align="center" bgcolor="#9AD3A4">
<tr>
<td width="90" align="center">用 户 名 :</td>
<td><input type="text" name="username" ></td>
</tr>
<tr>
<td width="90" align="center">密     码  :</td>
<td><input type="password" name="password" id="p1"></td>
</tr>
<tr>
<td width="90" align="center">确认密码:</td>
<td><input type="password" name="password1" id="p2"></td>
</tr>
<tr>
<td><input onclick="return check1()" type="submit" name="submit" value="提交" ></td>
<td><input type="reset" name="reste" value="重置"></td>
</tr>
</table>
</form>
</body>
</html>
<script language="JavaScript">
<!--
function check1()
{
if (document.form2.username.value.length == 0)
{
alert("请输入用户名!");
return false;
}
if (document.form2.password.value.length == 0)
{
alert("请输入密码!");
return false;
}
String pd1=document.getElementById("p1").value;
String pd2=document.getElementById("p2").value;
if (pd1!=pd2)
{
alert("两次密码不一致!");
return false;
}
return true;
}
//-->
</script>
pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
</head>
<body>
<form name="form2" action="sign_in_save.jsp" method="post">
<table width="410" align="center" bgcolor="#9AD3A4">
<tr>
<td width="90" align="center">用 户 名 :</td>
<td><input type="text" name="username" ></td>
</tr>
<tr>
<td width="90" align="center">密     码  :</td>
<td><input type="password" name="password" id="p1"></td>
</tr>
<tr>
<td width="90" align="center">确认密码:</td>
<td><input type="password" name="password1" id="p2"></td>
</tr>
<tr>
<td><input onclick="return check1()" type="submit" name="submit" value="提交" ></td>
<td><input type="reset" name="reste" value="重置"></td>
</tr>
</table>
</form>
</body>
</html>
<script language="JavaScript">
<!--
function check1()
{
if (document.form2.username.value.length == 0)
{
alert("请输入用户名!");
return false;
}
if (document.form2.password.value.length == 0)
{
alert("请输入密码!");
return false;
}
String pd1=document.getElementById("p1").value;
String pd2=document.getElementById("p2").value;
if (pd1!=pd2)
{
alert("两次密码不一致!");
return false;
}
return true;
}
//-->
</script>