summaryrefslogtreecommitdiff
path: root/includes/header.inc
diff options
context:
space:
mode:
authorMinteck <contact@minteck.org>2023-02-23 19:34:56 +0100
committerMinteck <contact@minteck.org>2023-02-23 19:34:56 +0100
commit3d1cd02f27518f1a04374c7c8320cd5d82ede6e9 (patch)
tree75be5fba4368472fb11c8015aee026b2b9a71888 /includes/header.inc
parent8cc1f13c17fa2fb5a4410542d39e650e02945634 (diff)
downloadpluralconnect-3d1cd02f27518f1a04374c7c8320cd5d82ede6e9.tar.gz
pluralconnect-3d1cd02f27518f1a04374c7c8320cd5d82ede6e9.tar.bz2
pluralconnect-3d1cd02f27518f1a04374c7c8320cd5d82ede6e9.zip
Updated 40 files, added 37 files, deleted 1103 files and renamed 3905 files (automated)
Diffstat (limited to 'includes/header.inc')
-rw-r--r--includes/header.inc40
1 files changed, 10 insertions, 30 deletions
diff --git a/includes/header.inc b/includes/header.inc
index 4261f1c..02cb190 100644
--- a/includes/header.inc
+++ b/includes/header.inc
@@ -12,7 +12,7 @@ if (file_exists($_SERVER['DOCUMENT_ROOT'] . "/includes/data/.test")) {
$isNormallyLoggedIn = false;
-require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/session.inc"; global $isLoggedIn; global $isUserLoggedIn;
+require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/session.inc"; global $isLoggedIn; global $isUserLoggedIn; global $isLowerLoggedIn;
if ($readOnly && $isLoggedIn || $readOnly && $isUserLoggedIn) {
$isLoggedIn = false;
$isUserLoggedIn = false;
@@ -21,12 +21,14 @@ if ($readOnly && $isLoggedIn || $readOnly && $isUserLoggedIn) {
$pages = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/pages.json"), true);
-function error($errno, $errstr, $file, $line) {
- echo('
+if (!function_exists("error")) {
+ function error($errno, $errstr, $file, $line) {
+ echo('
<!-- -->">
- <div class="alert alert-danger" style="text-align: left;">
- <b>Error ' . $errno . ':</b> ' . $errstr . ' [' . $file . ':' . $line . ']
- </div>');
+ <div class="alert alert-danger" style="text-align: left;">
+ <b>Error ' . $errno . ':</b> ' . $errstr . ' [' . $file . ':' . $line . ']
+ </div>');
+ }
}
if (isset($_GET['errors'])) {
@@ -54,7 +56,6 @@ require_once $_SERVER["DOCUMENT_ROOT"] . "/includes/bitset.inc";
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/banner.inc";
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/rainbow.inc";
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/functions.inc";
-require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/ical/main.php";
?>
<!doctype html>
@@ -65,32 +66,11 @@ require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/ical/main.php";
<link href="/assets/logo/custom.css" rel="stylesheet">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js"></script>
- <title><?= $title ? $title . " · " : "" ?>Cold Haze</title>
- <?php if (isset($_MemberName) && file_exists($_SERVER['DOCUMENT_ROOT'] . "/assets/uploads/pt-" . $_MemberName . ".png")): ?>
- <link rel="shortcut icon" href="/assets/uploads/pt-<?= $_MemberName ?>.png" type="image/png">
- <?php else: ?>
- <?php if (isset($_MemberPage) && file_exists($_SERVER['DOCUMENT_ROOT'] . "/assets/icons/favicon/" . $_MemberPage . ".png")): ?>
- <link rel="shortcut icon" href="/assets/icons/favicon/<?= $_MemberPage ?>.png" type="image/png">
- <?php else: ?>
- <?php if (isset($toplevel) && file_exists($_SERVER['DOCUMENT_ROOT'] . "/assets/icons/favicon/" . $toplevel . ".png")): ?>
- <link rel="shortcut icon" href="/assets/icons/favicon/<?= $toplevel ?>.png" type="image/png">
- <?php else: ?>
- <?php if (isset($_SystemPage) && file_exists($_SERVER['DOCUMENT_ROOT'] . "/assets/icons/favicon/" . $_SystemPage . ".png")): ?>
- <link rel="shortcut icon" href="/assets/icons/favicon/<?= $_SystemPage ?>.png" type="image/png">
- <?php else: ?>
- <?php if (isset($_SystemName) && file_exists($_SERVER['DOCUMENT_ROOT'] . "/assets/uploads/" . $_SystemName . ".png") && (!isset($_MemberName) || $_MemberName !== "fusion")): ?>
- <link rel="shortcut icon" href="/assets/uploads/<?= $_SystemName ?>.png" type="image/png">
- <?php else: ?>
- <link rel="shortcut icon" href="/assets/logo/newlogo.png" type="image/png">
- <?php endif; ?>
- <?php endif; ?>
- <?php endif; ?>
- <?php endif; ?>
- <?php endif; ?>
+ <title><?= $title && $title !== "-" ? $title . " · " : "" ?>Cold Haze</title>
+ <link rel="shortcut icon" href="/assets/logo/newlogo<?= $isLoggedIn || $isLowerLoggedIn ? "3" : "" ?>.png" type="image/png">
</head>
<body<?php if ($page["rail"] && $isLoggedIn && !$useNewUI): ?> id="admin-page"<?php endif; ?>>
<?php require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/navigation.inc"; global $navigation; ?>
- <?php require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/navbar.inc"; ?>
<?php if (!$useNewUI): ?>
<div style="margin-top: 60px;" id="top-of-page"></div>