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

38 lines
1.3 KiB
HTML
Raw Permalink Normal View History

{{ define "title" }}New Comment{{ end }}
{{ define "main" }}
2024-11-11 19:55:01 +00:00
<form action="/guestbooks/{{ shortIdToSlug .Guestbook.ShortId }}/comments/create" method="post">
<input type="hidden" name="csrf_token" value="{{.CSRFToken}}">
2024-11-11 19:55:01 +00:00
<div>
<label for="authorname">Name: </label>
{{ with .Form.FieldErrors.authorName }}
<label class="error">{{.}}</label>
{{ end }}
<input type="text" name="authorname" id="authorname" >
</div>
<div>
<label for="authoremail">Email: </label>
{{ with .Form.FieldErrors.authorEmail }}
<label class="error">{{.}}</label>
{{ end }}
<input type="text" name="authoremail" id="authoremail" >
</div>
<div>
<label for="authorsite">Site Url: </label>
{{ with .Form.FieldErrors.authorSite }}
<label class="error">{{.}}</label>
{{ end }}
<input type="text" name="authorsite" id="authorsite" >
</div>
<div>
<label for="content">Comment: </label>
{{ with .Form.FieldErrors.content }}
<label class="error">{{.}}</label>
{{ end }}
<textarea name="content" id="content"></textarea>
</div>
<div>
<input type="submit" value="Post">
</div>
</form>
{{ end }}