-
Notifications
You must be signed in to change notification settings - Fork 136
/
register.html
103 lines (99 loc) · 5.12 KB
/
register.html
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
{# This file is part of INGInious. See the LICENSE and the COPYRIGHTS files for #}
{# more information about the licensing of this file. #}
{% extends "layout.html" %}
{% block title %} {{ _("Register") }} {% endblock %}
{% block content %}
{% if error %}
<div class="alert alert-danger alert-dismissable">
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
{{ msg }}
</div>
{% elif msg %}
<div class="alert alert-success alert-dismissable">
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
{{ msg }}
</div>
{% endif %}
{% if reset is none %}
<div class="row justify-content-center">
<div class="col-md-6">
<h2>{{ _("Register in INGInious") }}</h2>
<form method="post" class="form-horizontal">
<div class="row">
<div class="col-sm-12">
<label class="control-label">{{ _("Username (min. 4 alphanumerical characters) :") }} </label>
<input name="username" type="text" class="form-control">
</div>
<div class="col-sm-12">
<label class="control-label">{{ _("Complete name :") }} </label>
<input name="realname" type="text" class="form-control">
</div>
<div class="col-sm-12">
<label class="control-label">{{ _("Email address :") }} </label>
<input name="email" type="text" class="form-control">
</div>
<div class="col-sm-6">
<label class="control-label">{{ _("Password (min. 6 characters) :") }} </label>
<input name="passwd" type="password" class="form-control">
</div>
<div class="col-sm-6">
<label class="control-label">{{ _("Confirm password :") }} </label>
<input name="passwd2" type="password" class="form-control">
</div>
{% if is_tos_defined %}
<div class="col-sm-12 mt-sm-3">
<input name="term_policy_check" type="checkbox"> {{ _("I have read the {a1start}Terms of service{a1end} and the {a2start}Privacy policy{a2end}.").format(a1start='<a href="/pages/'+ terms_page + '">', a1end='</a>', a2start='<a href="/pages/' + privacy_page + '">', a2end='</a>') | safe }}
</div>
{% endif %}
<div class="col-sm-12"><br />
<button type="submit" name="register" class="btn btn-primary btn-block"><i class="fa fa-sign-in"></i> {{ _("Sign up") }}</button>
</div>
</div>
</form>
</div>
<div id="lostpasswd" class="col-md-6">
<h2>{{_("Lost password ?")}}</h2>
<form method="post" class="form-horizontal">
<div class="row">
<div class="col-sm-12">
<label class="control-label">{{_("Email address :")}} </label>
<input name="recovery_email" type="text" class="form-control">
</div>
<div class="col-sm-12"><br />
<button type="submit" name="lostpasswd" class="btn btn-warning btn-block"><i class="fa fa-undo"></i> {{_("Reset my password")}}</button>
</div>
</div>
</form>
</div>
</div>
{% else %}
<h2></h2>
<div class="row justify-content-center">
<div class="col-md-6">
<div class="card">
<div class="card-header">
{{ _("Set new password for {} [{}]".format(reset["realname"],reset["username"])) }}
</div>
<div class="card-body">
<form method="post" class="form-horizontal">
<div class="row">
<div class="col-sm-6">
<label class="control-label">{{_("Password (min. 6 characters) :")}} </label>
<input name="passwd" type="password" class="form-control">
</div>
<div class="col-sm-6">
<label class="control-label">{{_("Confirm password :")}} </label>
<input name="passwd2" type="password" class="form-control">
</div>
<div class="col-sm-12"><br />
<input type="hidden" name="reset" value="{{reset['hash']}}">
<button type="submit" name="resetpasswd" class="btn btn-warning btn-block"><i class="fa fa-undo"></i> {{ _("Set new password") }}</button>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
{% endif %}
{% endblock %}