guestbook/ui/html/pages/usercreate.view.tmpl.html

31 lines
1.0 KiB
HTML
Raw Normal View History

{{ define "title" }}User Registration{{ end }}
{{ define "main" }}
<form action="/users/register" method="post">
2024-11-11 19:55:01 +00:00
<input type="hidden" name="csrf_token" value="{{.CSRFToken}}">
<div>
<label for="username">Username: </label>
{{ with .Form.FieldErrors.name }}
<label class="error">{{.}}</label>
{{ end }}
<input type="text" name="username" id="username" value="{{ .Form.Name }}" required />
</div>
<div>
<label for="email">Email: </label>
{{ with .Form.FieldErrors.email }}
<label class="error">{{.}}</label>
{{ end }}
<input type="text" name="email" id="email" value="{{ .Form.Email }}" required />
</div>
<div>
<label for="password">Password: </label>
{{ with .Form.FieldErrors.password }}
<label class="error">{{.}}</label>
{{ end }}
<input type="password" name="password" id="password" />
</div>
<div>
<input type="submit" value="Register"/>
</div>
</form>
{{ end }}