rework honkers page some
This commit is contained in:
parent
e05c112af4
commit
8cd2d1c9fa
2
honk.go
2
honk.go
|
@ -977,7 +977,7 @@ func savehonker(w http.ResponseWriter, r *http.Request) {
|
||||||
|
|
||||||
if honkerid > 0 {
|
if honkerid > 0 {
|
||||||
goodbye := r.FormValue("goodbye")
|
goodbye := r.FormValue("goodbye")
|
||||||
if goodbye == "goodbye" {
|
if goodbye == "F" {
|
||||||
db := opendatabase()
|
db := opendatabase()
|
||||||
row := db.QueryRow("select xid from honkers where honkerid = ? and userid = ?",
|
row := db.QueryRow("select xid from honkers where honkerid = ? and userid = ?",
|
||||||
honkerid, u.UserID)
|
honkerid, u.UserID)
|
||||||
|
|
|
@ -17,17 +17,15 @@
|
||||||
<section class="honk">
|
<section class="honk">
|
||||||
<header>
|
<header>
|
||||||
<img alt="avatar" src="/a?a={{ .XID }}">
|
<img alt="avatar" src="/a?a={{ .XID }}">
|
||||||
<p style="font-size: 1.8em">{{ .Name }}
|
<p style="font-size: 1.8em"><a href="/h/{{ .Name }}">{{ .Name }}<a>
|
||||||
</header>
|
</header>
|
||||||
<p>url: <a href="{{ .XID }}" rel=noreferrer>{{ .XID }}</a>
|
<p>url: <a href="{{ .XID }}" rel=noreferrer>{{ .XID }}</a>
|
||||||
<p>flavor: {{ .Flavor }}
|
<p>flavor: {{ .Flavor }}
|
||||||
<p><a href="/h/{{ .Name }}">honks</a>
|
|
||||||
<p>combos:{{ range .Combos }} <a href="/c/{{ . }}">{{ . }}</a>{{ end }}
|
|
||||||
<form action="/savehonker" method="POST">
|
<form action="/savehonker" method="POST">
|
||||||
<input type="hidden" name="CSRF" value="{{ $honkercsrf }}">
|
<input type="hidden" name="CSRF" value="{{ $honkercsrf }}">
|
||||||
<input type="hidden" name="honkerid" value="{{ .ID }}">
|
<input type="hidden" name="honkerid" value="{{ .ID }}">
|
||||||
<p>combos: <input type="text" name="combos" value="{{ range .Combos }}{{ . }} {{end}}">
|
<p>combos: <input type="text" name="combos" value="{{ range .Combos }}{{ . }} {{end}}">
|
||||||
<p>depart: <input type="text" name="goodbye" value="" autocomplete=off> (say "goodbye")
|
<p>depart: <input type="text" name="goodbye" placeholder="press F" value="" autocomplete=off>
|
||||||
<p><input type="submit" name="save" value="save">
|
<p><input type="submit" name="save" value="save">
|
||||||
</form>
|
</form>
|
||||||
</section>
|
</section>
|
||||||
|
|
Loading…
Reference in New Issue