require login to view (if enabled)
This commit is contained in:
19
views/login-required.ejs
Normal file
19
views/login-required.ejs
Normal file
@@ -0,0 +1,19 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
|
||||
|
||||
<head>
|
||||
<%- include("head", locals) %>
|
||||
</head>
|
||||
|
||||
<body class="preload">
|
||||
<%- include("navigation", locals) %>
|
||||
<div class="content">
|
||||
<h1>Authentication Required</h1>
|
||||
You must log in to access that page.
|
||||
<form action="/login" method="post">
|
||||
<button type="submit">Log In</button>
|
||||
</form>
|
||||
</div>
|
||||
<%- include("footer", locals) %>
|
||||
</body>
|
||||
</html>
|
@@ -14,6 +14,9 @@
|
||||
<li><a href="/?distro=arch">Arch Builds</a></li>
|
||||
<li><a href="/?distro=artix">Artix Builds</a></li>
|
||||
<li><a href="/build">New Build</a></li>
|
||||
<% if (locals.user) { %>
|
||||
<li><a href="/logout">Log Out</a></li>
|
||||
<% } %>
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
Reference in New Issue
Block a user