summary refs log tree commit diff stats
path: root/web/login.html
diff options
context:
space:
mode:
authorAndinus <andinus@nand.sh>2020-03-27 22:43:11 +0530
committerAndinus <andinus@nand.sh>2020-03-27 22:43:11 +0530
commitb0b83af1c45c2d5ee587dc96847e25c95a3d50b0 (patch)
tree09aeffb9ee5538a002d76457d2cfdc50257c67f2 /web/login.html
parent79b376a659a1d58db01f60ad049110363fbf15fc (diff)
downloadperseus-b0b83af1c45c2d5ee587dc96847e25c95a3d50b0.tar.gz
Add login handler
Diffstat (limited to 'web/login.html')
-rw-r--r--web/login.html52
1 files changed, 52 insertions, 0 deletions
diff --git a/web/login.html b/web/login.html
new file mode 100644
index 0000000..cd0d6a7
--- /dev/null
+++ b/web/login.html
@@ -0,0 +1,52 @@
+<!DOCTYPE html>
+<html lang="en">
+  <head>
+    <meta charset="utf-8">
+    <meta name="viewport" content="width=device-width, initial-scale=1">
+    <title>Login &middot; Perseus</title>
+    <link rel="stylesheet" href="https://andinus.nand.sh/static/style.css">
+    <link rel="stylesheet" href="https://andinus.nand.sh/static/perseus/style.css">
+    <link rel="icon" href="https://andinus.nand.sh/static/perseus/favicon.png" type="image/png">
+  </head>
+  <body>
+    <div id="content">
+      <h1 class="title">Perseus</h1>{{ if .SafeList }}
+      <ul>{{ range .SafeList }}
+        <li>{{ . }}</li>{{ end }}
+      </ul>{{end}} {{ if .List }}
+      <ul>{{ range .List }}
+        <li>{{ . }}</li>{{ end }}
+      </ul>{{end}} {{ if .Error }}
+      <ul class="error">{{ range .Error }}
+        <li>{{ . }}</li>{{ end }}
+      </ul>{{end}} {{ if .Success }}
+      <ul class="success">{{ range .Success }}
+        <li>{{ . }}</li>{{ end }}
+      </ul>{{end}} {{ if .Notice }}
+      <ul class="notice">{{ range .Notice }}
+        <li>{{ . }}</li>{{ end }}
+      </ul>{{end}}
+      <form action="./login" method="post">
+	<h4>Username</h4>
+        <input type="text" name="username" required>
+	<h4>Password</h4>
+	<input type="password" name="password" required>
+        <input type="submit" name="submit" value="Login!">
+      </form>
+    </div>
+    <div id="postamble" class="status">
+      <p class="postamble">
+	<a href="https://andinus.nand.sh/">Andinus</a>
+	&nbsp;/&nbsp;
+	<a href="https://andinus.nand.sh/perseus">Perseus</a>
+	<span style="float:right">
+	  Perseus {{ .Version }}
+	  &nbsp;/&nbsp;
+	  <a href="https://tildegit.org/andinus/perseus">
+	    Source Code
+	  </a>
+	</span>
+      </p>
+    </div>
+  </body>
+</html>