summaryrefslogtreecommitdiff
path: root/includes/templates
diff options
context:
space:
mode:
authorcflip <36554078+cflip@users.noreply.github.com>2021-04-23 18:43:12 -0600
committercflip <36554078+cflip@users.noreply.github.com>2021-04-23 18:43:12 -0600
commit6c9369ad85f2fb3dc61234b54db7e7079cdc0c4e (patch)
tree0275f6627930f6edff72b0ebba7813b746d3c228 /includes/templates
parentf469e37a0a5d90350a6abd6a0c7b92b019f377e1 (diff)
Refactoring part 1
Diffstat (limited to 'includes/templates')
-rw-r--r--includes/templates/404.php12
-rw-r--r--includes/templates/header.php14
2 files changed, 26 insertions, 0 deletions
diff --git a/includes/templates/404.php b/includes/templates/404.php
new file mode 100644
index 0000000..d4d5128
--- /dev/null
+++ b/includes/templates/404.php
@@ -0,0 +1,12 @@
+<!DOCTYPE html>
+<html>
+<head>
+ <title>cflip.net forum</title>
+ <link rel="stylesheet" href="styles/style.css">
+</head>
+<body>
+ <?php include_once 'header.php'; ?>
+ <h1>Page Not Found</h1>
+ <p>The page you requested does not exist.</p>
+</body>
+</html>
diff --git a/includes/templates/header.php b/includes/templates/header.php
new file mode 100644
index 0000000..4eb17e3
--- /dev/null
+++ b/includes/templates/header.php
@@ -0,0 +1,14 @@
+<h1>cflip.net forum<sup style="font-size: small;">beta</sup></h1>
+[<a href="/">Home</a>]
+[<a href="/search.php?type=thread&sort=lr">All Threads</a>]
+[<a href="/search.php?type=post&sort=cd">All Posts</a>]
+[<a href="/create_thread.php">Create a thread</a>]
+<span style="float:right;">
+ <?php
+ if (isset($_SESSION['signed_in'])) {
+ echo '[<a href="viewuser.php?id='. $_SESSION['user_id'] .'">' . $_SESSION['user_name'] . '\'s Profile</a>] [<a href="includes/signout_inc.php">Log out</a>]';
+ } else {
+ echo '[<a href="signin.php">Sign in</a>] or [<a href="register.php">Register an account</a>]';
+ }
+ ?>
+</span>