summaryrefslogtreecommitdiff
path: root/views/header.ejs
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2021-05-01 00:48:35 +0200
committerTor Andersson <tor@ccxvii.net>2021-05-01 00:48:35 +0200
commit652852e3104ce4020de53231ee7691a4970439d6 (patch)
tree57a053cb2104520e240cd44a4dfb9f92fd5ede07 /views/header.ejs
parent156f7f8546890c6406001061dae199f8320ca83b (diff)
downloadserver-652852e3104ce4020de53231ee7691a4970439d6.tar.gz
Add server and lobby code.
Diffstat (limited to 'views/header.ejs')
-rw-r--r--views/header.ejs32
1 files changed, 32 insertions, 0 deletions
diff --git a/views/header.ejs b/views/header.ejs
new file mode 100644
index 0000000..9e101dd
--- /dev/null
+++ b/views/header.ejs
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1">
+<% if (typeof refresh != 'undefined' && refresh > 0) { %><meta http-equiv="refresh" content="<%= refresh %>"><% } %>
+<link rel="icon" href="/images/rally-the-troops.png">
+<link rel="stylesheet" href="/fonts/fonts.css">
+<link rel="stylesheet" href="/style.css">
+<title><%= title %></title>
+</head>
+<body>
+<div class="header">
+<div><a href="/"><img src="/images/rally-the-troops.svg" width="48" height="48"></a></div>
+<div>
+<span><a href="/about">About</a></span>
+<%
+ if (user) {
+ %><span><a href="/profile">Profile (<%= user.name %>)</a></span><%
+ } else {
+ %><span><a href="/signup">Signup</a></span><%
+ %><span><a href="/login">Login</a></span><%
+ }
+%>
+</div>
+</div>
+<div class="main">
+<h1><%= title %></h1>
+<%
+ if (typeof message != 'undefined' && message.length > 0) {
+ %><p class="error"><%= Array.isArray(message) ? message.join("\n") : message %></p><%
+ }
+%>