35 lines
2.1 KiB
HTML
35 lines
2.1 KiB
HTML
{{define "register on x"}}Register on {{.}}{{end}}
|
|
{{define "title"}}{{template "register on x" .WikiName}}{{end}}
|
|
{{define "body"}}
|
|
<main class="main-width">
|
|
<section>
|
|
{{if .AllowRegistration}}
|
|
<form class="modal" method="post" action="/register?{{.RawQuery}}" id="register-form" enctype="multipart/form-data" autocomplete="off">
|
|
<fieldset class="modal__fieldset">
|
|
<legend class="modal__title">{{template "register on x" .WikiName}}</legend>
|
|
{{if .Err}}<p class="error">{{.Err.Error}}</p>{{end}}
|
|
|
|
<label for="register-form__username">{{block "username" .}}Username{{end}}</label>
|
|
<br>
|
|
<input type="text" required autofocus id="register-form__username" name="username"{{if .Username}} value="{{.Username}}"{{end}}>
|
|
<br>
|
|
<label for="register-form__password">{{block "password" .}}Password{{end}}</label>
|
|
<br>
|
|
<input type="password" required name="password" id="register-form__password"{{if .Password}} value="{{.Password}}"{{end}}>
|
|
<p>{{block "password tip" .}}The server stores your password in an encrypted form; even administrators cannot read it.{{end}}</p>
|
|
<p>{{block "cookie tip" .}}By submitting this form you give this wiki a permission to store cookies in your browser. It lets the engine associate your edits with you. You will stay logged in until you log out.{{end}}</p>
|
|
<button class="btn" type="submit">{{block "register btn" .}}Register{{end}}</button>
|
|
<a class="btn btn_weak" href="/{{.RawQuery}}">{{block "cancel" .}}Cancel{{end}}</a>
|
|
</fieldset>
|
|
</form>
|
|
{{template "telegram widget" .}}
|
|
{{else if .UseAuth}}
|
|
<p>{%s lc.Get("auth.noregister") %}</p>
|
|
<p><a href="/{{.RawQuery}}">← {%s lc.Get("auth.go_back") %}</a></p>
|
|
{{else}}
|
|
<p>{%s lc.Get("auth.noauth") %}</p>
|
|
<p><a href="/{{.RawQuery}}">← {%s lc.Get("auth.go_back") %}</a></p>
|
|
{{end}}
|
|
</section>
|
|
</main>
|
|
{{end}} |