Migrate to cookie based session (secure cookie)

finish sign-in sign-up
This commit is contained in:
Wancat
2022-10-21 16:57:10 +08:00
parent 8661c0081d
commit bc1095fc61
7 changed files with 114 additions and 30 deletions

10
templates/signin.html Normal file
View File

@@ -0,0 +1,10 @@
{{ define "title" }}Sign Up{{ end }}
{{ define "main" }}
<h1>Sign In</h1>
<form action="/signin" method="POST">
<label>Email: <input type="text" name="email"></label><br>
<label>Password: <input type="password" name="password"></label><br>
{{ with .Error }}<p class="error">{{ . }}</p>{{ end }}
<input type="submit" value="Sign Up">
</form>
{{ end }}