From 9b44a1339844079f14dfe2c79fe34ad3ebf891c9 Mon Sep 17 00:00:00 2001
From: Conrad Zelck <git@simpel.cc>
Date: Thu, 14 Apr 2022 17:39:30 +0200
Subject: [PATCH] feat: introduce global head/header

Signed-off-by: Conrad Zelck <git@simpel.cc>
---
 index.php               | 19 ++-----------------
 localSettingsHeader.php |  6 ++++++
 2 files changed, 8 insertions(+), 17 deletions(-)
 create mode 100644 localSettingsHeader.php

diff --git a/index.php b/index.php
index 75a2977..ba7b866 100644
--- a/index.php
+++ b/index.php
@@ -1,26 +1,11 @@
 <html lang="en">
   <head>
-    <meta charset="utf-8">
-    <meta name="robots" content="noindex,nofollow">
-    <meta name="referrer" content="no-referrer">
-    <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
-    <meta http-equiv="Pragma" content="no-cache">
-    <meta http-equiv="Expires" content="0">
-    <meta name="author" content="Simpel">
-    <meta name="copyright" content="MIT 2021 Simpel">
-    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=yes user-scalable=no">
-    <title>Comment Syntax</title>
+    <?php include dirname($_SERVER['DOCUMENT_ROOT']) . "/simpel.cc/php/head.php"; ?>
     <link rel="stylesheet" href="style.css">
   </head>
   <body>
     <header>
-      <nav>
-        <a id="logo" class="cursordefault" href="/"><img src="../Simpel.png" alt="simpel icon" height="48" width="48"></a>
-        <h1>Comment Syntax</h1>
-        <a id="github" href="https://github.com/SimpelMe/comment-syntax-finder" target="_blank" title="watch source code">
-          <img id="github-cat" src="../github.svg" alt="github logo">
-        </a>
-      </nav>
+      <?php include dirname($_SERVER['DOCUMENT_ROOT']) . "/simpel.cc/php/header.php"; ?>
     </header>
     <main>
       <div>
diff --git a/localSettingsHeader.php b/localSettingsHeader.php
new file mode 100644
index 0000000..9cc421f
--- /dev/null
+++ b/localSettingsHeader.php
@@ -0,0 +1,6 @@
+<?php
+  define("SITE_TITLE", "Comment Syntax");
+  define("SITE_COPYRIGHT_CONTENT", "MIT 2021 Simpel");
+  define("SITE_H1", "Comment Syntax");
+  define("SITE_GITHUB", "https://github.com/SimpelMe/comment-syntax-finder");
+?>
-- 
GitLab