📄 adduser.jsp
字号:
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
<title>EHBS</title>
</head>
<BODY bgColor=#6597d9>
<%
Object or = request.getAttribute("adduserresult");
if(or != null){
%>
<p align = "center">
<%=or.toString()%>
</p>
<%
request.setAttribute("adduserresult",null);
}
else if(null != request.getParameter("name")) {
%>
<jsp:forward page="/addUserServlet" />
<%
}
else{
%>
<form name="form1" method="post" action="">
<p>Name
<input type="text" name="name">
</p>
<p>Password
<input type="password" name="password">
</p>
<p>Repeat Password
<input type="password" name="password2">
</p>
<p>Gender
<select name="gender" size="1">
<option>Male</option>
<option>Female</option>
</select>
</p>
<p>Card ID
<input type="text" name="card">
</p>
<p>BirthDay
Year<select name="birthyear">
<%
for(int i =1900;i<2005;i++){
%>
<option><%=i%></option>
<%
}
%>
</select>
Month<select name="birthmonth">
<%
for(int i =1;i<12;i++){
%>
<option><%=i%></option>
<%
}
%>
</select>
Day<select name="birthday">
<%
for(int i =1;i<31;i++){
%>
<option><%=i%></option>
<%
}
%>
</select>
</p>
<p>Nationality
<input type="text" name="nation">
</p>
<p>City
<input type="text" name="city">
</p>
<p>Address
<input type="text" name="addr">
</p>
<p>Phone
<input type="text" name="phone">
</p>
<p>Mobile Phone
<input type="text" name="mobile">
</p>
<p>Email
<input type="text" name="email">
</p>
<p>
<input type="submit" name="Submit" value="Summit">
<input type="reset" name="Submit2" value="Reset">
</p>
</form>
<%
}
%>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -