templates/age.html
{{ define "age.html" }} {{ template "head" . }} {{ template "nav" . }} <h3>tools/age</h3> <p>use this form to encrypt age data for people, if you want. my public key is <pre>age12amwzaps3lfy5y7kup5h730d2alfcpxlrnahgxv7u4a877hl9c8s6h2wuf</pre></p> <form method="POST"> <label>age public key</label><br /> <input type="text" name="pubkey" size="60" required><br /> <label>text to encrypt</label><br /> <textarea name="message" rows="10" cols="60" required></textarea><br /> <input type="submit"> </form> {{ if . }} <h3>result</h3> <pre> {{ .Data }} </pre> {{ end }} {{ end }}