login.html
1.61 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
{% extends "website/baseline.html" %}
{% block content %}
<style type="text/css">
.login-form {
width: 340px;
margin: 50px auto;
}
.login-form form {
margin-bottom: 15px;
background: #BCD8F2;
box-shadow: 0px 2px 2px rgba(0, 0, 0, 0.3);
padding: 30px;
}
.login-form h2 {
margin: 0 0 15px;
font-weight:bold;
}
.form-control, .btn {
min-height: 38px;
border-radius: 2px;
}
.btn {
font-size: 15px;
font-weight: bold;
}
a {
color: #3A5AC1;
}
table {
border-spacing: 10px;
border-collapse: separate;
}
</style>
<div class="login-form">
<form action="{% url 'login' %}" method="post">
{% csrf_token %}
<h2 class="text-center">Log in</h2>
<table>
<tr>
<td>Username </td>
<td>{{ form.username }}</td>
</tr>
<tr>
<td>Password </td>
<td>{{ form.password }}</td>
</tr>
</table>
<br>
<input type="submit" class="btn btn-primary btn-block" value="Login"role="button"/>
<input type="hidden" name="next" value="{{ next }}" />
</div>
</form>
<p class="text-center"><a href="{% url 'signup' %}">Create an Account</a></p>
</div>
{% if form.errors %}
<p style="text-align: center">이름과 비밀번호가 일치하지 않습니다. 다시 시도해주세요.</p>
{% endif %}
{% endblock %}