login.html
1.33 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
{% extends "base.html" %}
{% load i18n %}
{% load url from future %}
{% block content %}
{% if form.errors and not form.non_field_errors and not form.this_is_the_login_form.errors %}
<p class="errornote">
{% blocktrans count form.errors.items|length as counter %}Please correct the error below.{% plural %}Please correct the errors below.{% endblocktrans %}
</p>
{% endif %}
{% if form.non_field_errors or form.this_is_the_login_form.errors %}
{% for error in form.non_field_errors|add:form.this_is_the_login_form.errors %}
<p class="errornote">
{{ error }}
</p>
{% endfor %}
{% endif %}
<div id="content-main">
<div id="login-box">
<form action="" method="post" id="login-form">{% csrf_token %}
<table>
{{ form.as_table }}
</table>
<div class="submit-row">
<label> </label>
<input type="submit" value="{% trans 'Log in' %}"/>
</div>
</form>
<a href="{% url 'auth_password_reset' %}">{% trans 'I forgot my password' %}</a>
</div>
<script type="text/javascript">
document.getElementById('id_username').focus()
</script>
</div>
{% endblock %}