diff options
author | Minteck <contact@minteck.org> | 2023-02-22 22:06:58 +0100 |
---|---|---|
committer | Minteck <contact@minteck.org> | 2023-02-22 22:06:58 +0100 |
commit | 6563d542af0930ebb6b2f9b71f2b7538d7467665 (patch) | |
tree | 2d0c1f34382ab3c1fc4a7422cc87be2a5714356e /pages | |
parent | 737f5008f8a4a011c832e83f6b2019d3dc27dbd0 (diff) | |
download | pluralconnect-6563d542af0930ebb6b2f9b71f2b7538d7467665.tar.gz pluralconnect-6563d542af0930ebb6b2f9b71f2b7538d7467665.tar.bz2 pluralconnect-6563d542af0930ebb6b2f9b71f2b7538d7467665.zip |
Updated 8 files (automated)
Diffstat (limited to 'pages')
-rw-r--r-- | pages/actions.inc | 1 | ||||
-rw-r--r-- | pages/byfront.inc | 2 | ||||
-rw-r--r-- | pages/front.inc | 6 | ||||
-rw-r--r-- | pages/home.inc | 14 | ||||
-rw-r--r-- | pages/pleasure.inc | 1 | ||||
-rw-r--r-- | pages/toys.inc | 1 |
6 files changed, 16 insertions, 9 deletions
diff --git a/pages/actions.inc b/pages/actions.inc index 40a359a..630626a 100644 --- a/pages/actions.inc +++ b/pages/actions.inc @@ -1,5 +1,6 @@ <?php +return; require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; global $isLoggedIn; global $lang; global $pages; if (isset($_POST['deleteAction'])) { diff --git a/pages/byfront.inc b/pages/byfront.inc index 93fe3d5..00000b6 100644 --- a/pages/byfront.inc +++ b/pages/byfront.inc @@ -110,7 +110,7 @@ $travelling = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includ } } - if (isset($age) && $age > 0 && time() > 1677628800): ?> + if ((isset($age) && $age > 0 && time() > 1677628800) || time() <= 1677628800): ?> <div class="relation" style="background-color:<?php if ($member["_metadata"]["less_frequent"] || $member["_metadata"]["persecutor"]): ?><?php if ($member["_lastFronted"] > time() - (86400 * 21)): ?>rgba(255, 255, 255, .1)<?php else: ?><?php if ($member["_lastFronted"] > time() - (86400 * 37)): ?>rgba(255, 227, 0, 0.17)rgba(128,54,54,0.17)<?php endif; ?>;<?php endif; ?><?php else: ?><?php if ($member["_lastFronted"] > time() - (86400 * 21)): ?>rgba(255, 255, 255, .1)<?php else: ?><?php if ($member["_lastFronted"] > time() - (86400 * 30)): ?>rgba(255, 227, 0, 0.17)<?php else: ?>rgba(255,55,55,0.17)<?php endif; ?>;<?php endif; ?><?php endif; ?>;margin-bottom:10px;padding:10px;border-radius:10px;display:grid;grid-template-columns: 1fr 2fr max-content;<?php if ($travelling[$member['id']]["travelling"]): ?>opacity: 0.75;<?php endif; ?><?php if (isset($member["_metadata"]["not_fronting"]) && $member["_metadata"]["not_fronting"]): ?>background-color:rgba(255, 255, 255, .1) !important;<?php endif; ?>"> <a class="relation-intro" style="background-color:rgba(255, 255, 255, .05);border-right:1px solid rgba(255, 255, 255, .1);margin:-10px;padding:10px;border-top-left-radius:10px;border-bottom-left-radius:10px;color: white;display:flex;align-items:center;text-decoration: none;" href="/<?= $member["name"] ?>"> <img src="<?= getAsset($member['system'], $member["id"], "heads") ?>" style="width:24px;"> <?= $member["display_name"] ?? $member["name"] ?> diff --git a/pages/front.inc b/pages/front.inc index a60be1d..cd4f952 100644 --- a/pages/front.inc +++ b/pages/front.inc @@ -2,15 +2,13 @@ $parts = explode("/", $_GET["_"]); -var_dump($parts); - if (isset($parts[2])) { if ($parts[2] === "cloudburst") { $fronters = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/ynmuc/fronters.json"), true); } elseif ($parts[2] === "raindrops") { $fronters = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/gdapd/fronters.json"), true); } else { - header("Location: /"); + header("Location: /?error=Invalid argument; got " . $parts[2]); die(); } @@ -25,6 +23,6 @@ if (isset($parts[2])) { } } } else { - header("Location: /"); + header("Location: /?error=Missing operand"); die(); }
\ No newline at end of file diff --git a/pages/home.inc b/pages/home.inc index 44c8d7e..d476991 100644 --- a/pages/home.inc +++ b/pages/home.inc @@ -1,4 +1,4 @@ -<?php if (isset($_GET['error'])) header("HTTP/1.1 404 Not Found"); require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/header.inc'; global $readOnly; global $isNormallyLoggedIn; global $_PROFILE; global $lang; global $pages; global $isLowerLoggedIn; ?> +<?php if (isset($_GET['error'])) header("HTTP/1.1 404 Not Found"); require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/header.inc'; global $readOnly; global $isNormallyLoggedIn; global $_PROFILE; global $lang; global $pages; global $isLowerLoggedIn; global $isLoggedIn; ?> <br> <div class="container"> @@ -9,7 +9,7 @@ </div> <?php endif; ?> - <?php if ($readOnly && $isNormallyLoggedIn): ?> + <?php if ($readOnly && $isNormallyLoggedIn || $readOnly && $isLowerLoggedIn): ?> <div class="alert alert-warning"> <b>Notice: </b>This website is temporarily under maintenance and the administrators have locked the database. Although you are logged in as <?= $_PROFILE['name'] ?>, you cannot access any of the logged-in features while the website is under maintenance. <a href="/-/emergency">Alerts dispatching</a> remains possible in case of an emergency. </div> @@ -31,19 +31,23 @@ <?php if ($_SERVER['HTTP_HOST'] === "fr.equestria.horse"): ?> <p><?= count($byColor) ?> poneys dans une tĂȘte</p> <?php else: ?> + <?php if ($isLoggedIn || $isLowerLoggedIn): ?> + <p><?= count($byColor) ?> ponies in 3 plural systems</p> + <?php else: ?> <p><?= count($byColor) ?> <?= $lang["home"]["intro"] ?></p> <?php endif; ?> + <?php endif; ?> </div> </div> <hr style="border-color:rgba(255, 255, 255, .25);"> - <?php global $isLoggedIn; if ($isLoggedIn && ((int)date('H') >= 20 || (int)date('H') < 6)): ?> + <!--<?php global $isLoggedIn; if ($isLoggedIn && ((int)date('H') >= 20 || (int)date('H') < 6)): ?> <a href="/-/emergency" style="text-decoration: none;margin-top:15px;display:block;"> <div class="alert alert-danger"> <b>Are you in need of help?</b> If you need immediate help from a loved one, you may want to enable the emergency alert by clicking here, even if that wakes up the <?= $_PROFILE['name'] === "Raindrops System" ? "Cloudburst System" : "Raindrops System" ?>. Use it as you need. </div> </a> - <?php endif; ?> + <?php endif; ?>--> <!--<div class="alert alert-info"> <b>Coming soon:</b> Free hosting for Project Scout (the software powering Cold Haze), so you can have your own website for your system. If you are interested and/or want to pre-register, feel free to <a href="https://equestria.horse/contact" target="_blank">contact us</a>. @@ -55,6 +59,8 @@ <?php raindrops(false); ?> <?php if ($isLoggedIn || $isLowerLoggedIn) other(false); ?> + <hr> + <div id="hpd-legacy" style="background:rgba(255, 255, 255, .1);border-radius:10px;padding:10px 10px 10px 20px;display:grid;grid-template-columns: 128px 1fr;margin-bottom:10px;"> <a style="display:flex;margin: -10px -20px;align-items:center;justify-content:center;text-align:center;padding: 10px 20px;border-radius: 10px;background: #77777755;width: 148px;text-decoration:none;color:white;filter:none !important;" class="hpd-system"> <div style="text-align:center;"><img src="/assets/icons/legacy.svg" style="width:64px;"><br>Pony Legacy</div> diff --git a/pages/pleasure.inc b/pages/pleasure.inc index 30ccf3d..ac59cfd 100644 --- a/pages/pleasure.inc +++ b/pages/pleasure.inc @@ -1,5 +1,6 @@ <?php +return; require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; global $isLoggedIn; global $lang; global $pages; $emergencyHeader = true; require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/header.inc'; diff --git a/pages/toys.inc b/pages/toys.inc index 9032944..4c172c6 100644 --- a/pages/toys.inc +++ b/pages/toys.inc @@ -1,5 +1,6 @@ <?php +return; require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; if (isset($_POST['deleteAction'])) { |