-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlogin.jsp
More file actions
69 lines (59 loc) · 1.6 KB
/
login.jsp
File metadata and controls
69 lines (59 loc) · 1.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<%--
Created by IntelliJ IDEA.
User: cpucode
Date: 2020/11/8
Time: 16:49
To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
<title>login</title>
<script>
window.onload = function () {
document.getElementById("img").onclick = function () {
this.src = "/login_servlet/check_code_session?time=" + new Date().getTime();
}
}
</script>
<style>
div{
color: red;
}
</style>
</head>
<body>
<form action="/login_servlet/login_servlet" method="post">
<table>
<tr>
<td>用户名</td>
<td><input type="text" name="username"></td>
</tr>
<tr>
<td>密码</td>
<td><input type="password" name="password"></td>
</tr>
<tr>
<td>验证码</td>
<td><input type="text" name="checkCode"></td>
</tr>
<tr>
<td colspan="2"><img id="img" src="/login_servlet/check_code_session"></td>
</tr>
<tr>
<td colspan="2"><input type="submit" value="登录"></td>
</tr>
</table>
</form>
<div>
<%=
request.getAttribute("cc_error") == null ? "" : request.getAttribute("cc_error")
%>
</div>
<div>
<%=
request.getAttribute("login_error") == null ? "" : request.getAttribute("login_error")
%>
</div>
</body>
</html>