From 23563c7188e089929b60f9e10721c6fc43a220ff Mon Sep 17 00:00:00 2001 From: RaindropsSys Date: Thu, 22 Jun 2023 23:06:12 +0200 Subject: Updated 15 files, added includes/maintenance/deleteUnusedAssets.php and deleted 4944 files (automated) --- pages/api/badger.php | 3 + pages/api/browser.php | 4 - pages/api/chrome.php | 90 ------ pages/api/desktop.php | 3 - pages/api/fronter.php | 177 ----------- pages/api/wear/schedule.php | 117 -------- pages/fronting.inc | 20 -- pages/games.inc | 83 ------ pages/home.inc | 5 + pages/home.old.inc | 79 ----- pages/rules.inc | 289 ------------------ pages/schedules.inc | 79 ----- pages/toys.inc | 697 -------------------------------------------- 13 files changed, 8 insertions(+), 1638 deletions(-) delete mode 100644 pages/api/browser.php delete mode 100644 pages/api/chrome.php delete mode 100644 pages/api/desktop.php delete mode 100644 pages/api/fronter.php delete mode 100644 pages/api/wear/schedule.php delete mode 100644 pages/fronting.inc delete mode 100644 pages/games.inc delete mode 100644 pages/home.old.inc delete mode 100644 pages/rules.inc delete mode 100644 pages/toys.inc (limited to 'pages') diff --git a/pages/api/badger.php b/pages/api/badger.php index 0682041..ee7bfa7 100644 --- a/pages/api/badger.php +++ b/pages/api/badger.php @@ -2,6 +2,9 @@ require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/util/functions.inc"; +global $isLoggedIn; global $isLowerLoggedIn; +$isLoggedIn = false; $isLowerLoggedIn = false; + $list = scoreOrderGlobal(); function getAge($metadata) { diff --git a/pages/api/browser.php b/pages/api/browser.php deleted file mode 100644 index 657b2a7..0000000 --- a/pages/api/browser.php +++ /dev/null @@ -1,4 +0,0 @@ - - - - - - - - - Luna for Chrome OS - - - -
-
- -

Please login to Cold Haze

-

To proceed with activating Luna on this Chromebook, you need to login to Cold Haze. You also need to make sure you properly enroled this computer into Chrome Enterprise.

- -
-
- - - - - -1 ? $index - 1 : $index); - file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/planner.json", "{}"); - createJob("RefreshCache", []); - - break; - - case "top": - if (!isset($index) || trim($index) === "" || !is_integer($index)) { - if ($index !== null) peh_error("Invalid index", 400); - } - - $day = $list[$date]; - - if (!isset($day[$index])) { - if ($index !== null) peh_error("Index not found", 404); - } - - moveElement($list[$date], $index, 0); - file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/planner.json", "{}"); - createJob("RefreshCache", []); - - break; - - default: - peh_error("Invalid type name", 400); - break; -} - -file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/planner/$system.json", json_encode($list)); - -die(); \ No newline at end of file diff --git a/pages/api/wear/schedule.php b/pages/api/wear/schedule.php deleted file mode 100644 index cf053d8..0000000 --- a/pages/api/wear/schedule.php +++ /dev/null @@ -1,117 +0,0 @@ - [], - "tomorrow" => [] -]; - -$raindrops = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/planner/gdapd.json"), true); -$cloudburst = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/planner/ynmuc.json"), true); - -if (isset($raindrops[date('Y-m-d', time())]) || isset($cloudburst[date('Y-m-d', time())])) { - $rd = $raindrops[date('Y-m-d', time())]; - $cb = $cloudburst[date('Y-m-d', time())]; - $longest = max(count($rd), count($cb)); - - for ($x = 0; $x < $longest; $x++) { - $item = []; - $item["raindrops"] = null; - $item["cloudburst"] = null; - - if (isset($rd[$x])) { - $item["raindrops"] = array_map(function ($i) use ($x, $longest) { - $member = getMemberWithoutSystem($i); - - return [ - "id" => $member["id"], - "name" => $member["display_name"] ?? $member["name"], - "avatar" => "https://ponies.equestria.horse" . getAsset($member["_system"], $member["id"]), - "flags" => [ - "pacifier" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["pacifier"] ?? false) && ($x === ($longest - 1)), - "plush" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["sleep_plush"] ?? false) && ($x === ($longest - 1)), - ] - ]; - }, array_filter($rd[$x], function ($i) { return isset($i); })); - } else if (isset($obj["today"][$x - 1]["raindrops"])) { - $item["raindrops"] = $obj["today"][$x - 1]["raindrops"]; - } - - if (isset($cb[$x])) { - $item["cloudburst"] = array_map(function ($i) use ($x, $longest) { - $member = getMemberWithoutSystem($i); - - return [ - "id" => $member["id"], - "name" => $member["display_name"] ?? $member["name"], - "avatar" => "https://ponies.equestria.horse" . getAsset($member["_system"], $member["id"]), - "flags" => [ - "pacifier" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["pacifier"] ?? false) && ($x === ($longest - 1)), - "plush" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["sleep_plush"] ?? false) && ($x === ($longest - 1)), - ] - ]; - }, array_filter($cb[$x], function ($i) { return isset($i); })); - } else if (isset($obj["today"][$x - 1]["cloudburst"])) { - $item["cloudburst"] = $obj["today"][$x - 1]["cloudburst"]; - } - - $obj["today"][] = $item; - } -} - -if (isset($raindrops[date('Y-m-d', time() + 86400)]) || isset($cloudburst[date('Y-m-d', time() + 86400)])) { - $rd = $raindrops[date('Y-m-d', time() + 86400)]; - $cb = $cloudburst[date('Y-m-d', time() + 86400)]; - $longest = max(count($rd), count($cb)); - - for ($x = 0; $x < $longest; $x++) { - $item = []; - $item["raindrops"] = null; - $item["cloudburst"] = null; - - if (isset($rd[$x])) { - $item["raindrops"] = array_map(function ($i) use ($x, $longest) { - $member = getMemberWithoutSystem($i); - - return [ - "id" => $member["id"], - "name" => $member["display_name"] ?? $member["name"], - "avatar" => "https://ponies.equestria.horse" . getAsset($member["_system"], $member["id"]), - "flags" => [ - "pacifier" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["pacifier"] ?? false) && ($x === ($longest - 1)), - "plush" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["sleep_plush"] ?? false) && ($x === ($longest - 1)), - ] - ]; - }, array_filter($rd[$x], function ($i) { return isset($i); })); - } else if (isset($obj["tomorrow"][$x - 1]["raindrops"])) { - $item["raindrops"] = $obj["tomorrow"][$x - 1]["raindrops"]; - } - - if (isset($cb[$x])) { - $item["cloudburst"] = array_map(function ($i) use ($x, $longest) { - $member = getMemberWithoutSystem($i); - - return [ - "id" => $member["id"], - "name" => $member["display_name"] ?? $member["name"], - "avatar" => "https://ponies.equestria.horse" . getAsset($member["_system"], $member["id"]), - "flags" => [ - "pacifier" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["pacifier"] ?? false) && ($x === ($longest - 1)), - "plush" => (json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/metadata/" . $member["id"] . ".json"), true)["sleep_plush"] ?? false) && ($x === ($longest - 1)), - ] - ]; - }, array_filter($cb[$x], function ($i) { return isset($i); })); - } else if (isset($obj["tomorrow"][$x - 1]["cloudburst"])) { - $item["cloudburst"] = $obj["tomorrow"][$x - 1]["cloudburst"]; - } - - $obj["tomorrow"][] = $item; - } -} - -die(json_encode($obj, JSON_PRETTY_PRINT)); \ No newline at end of file diff --git a/pages/fronting.inc b/pages/fronting.inc deleted file mode 100644 index 1c16a80..0000000 --- a/pages/fronting.inc +++ /dev/null @@ -1,20 +0,0 @@ -= 1686787200) { - header("Location: /evening"); - die(); -} - -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; global $isLoggedIn; global $lang; global $pages; -require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/components/header.inc'; - -?> - -
-
-
- -
-
- - diff --git a/pages/games.inc b/pages/games.inc deleted file mode 100644 index ca881e4..0000000 --- a/pages/games.inc +++ /dev/null @@ -1,83 +0,0 @@ - - - - -
-
-

51st Equestria Games

-

- June 30th โ€” July 6th
Maretime Bay, Equestria
-

-

- Apply now
- (applications open on April 1st until May 1st) -

-
- Participating ponies (): " style="width: 24px;" title="" data-bs-toggle="tooltip" class="tooltip-nohelp"> -
- -
-

List of games

- -
-
Volleyball
-
Paddleboat
-
Magic
-
Swimming
-
Relay
-
- -
-

Schedule

- - -
-

How does it work?

- - -
-

Rules

- -
- - diff --git a/pages/home.inc b/pages/home.inc index e9a5426..62474d3 100644 --- a/pages/home.inc +++ b/pages/home.inc @@ -71,6 +71,11 @@ function members() { global $isLoggedIn; global $isLowerLoggedIn; global $app; ? + +
Notice: This website is temporarily under maintenance and the administrators have locked the database. Although you are logged in as , you cannot access any of the logged-in features while the website is under maintenance. Alerts dispatching remains possible in case of an emergency. diff --git a/pages/home.old.inc b/pages/home.old.inc deleted file mode 100644 index 085af58..0000000 --- a/pages/home.old.inc +++ /dev/null @@ -1,79 +0,0 @@ - - -
-
- -
- - -
- - - -
- Notice: This website is temporarily under maintenance and the administrators have locked the database. Although you are logged in as , you cannot access any of the logged-in features while the website is under maintenance. Alerts dispatching remains possible in case of an emergency. -
- - - -
- .png" style="width:128px;"> -

-
" data-bs-toggle="tooltip" style="overflow: hidden;" href="/">" style="height:32px;position:absolute;z-index:99;">
-

-
-
- ;z-index: 9;margin-left: 8px;opacity: .75;"> -
-
-
-

Cold Haze

- -

ponies in 3 plural systems

- -

- -
-
-
- -
- - - - - -
- -
- -

Pony Legacy
-
- -
-
- -
' . ($member['name'] ?? $id) . '
-
' . date('j M Y', strtotime($member["date"])) . '
-
'); - - endforeach; ?> -
-
- -
-
- - \ No newline at end of file diff --git a/pages/rules.inc b/pages/rules.inc deleted file mode 100644 index 0c57819..0000000 --- a/pages/rules.inc +++ /dev/null @@ -1,289 +0,0 @@ -= 1682985600) { - peh_error("Page not found: rules", 404); -} - -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/util/functions.inc"; -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; global $isLoggedIn; global $lang; global $pages; -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/util/Parsedown.php"; $Parsedown = new Parsedown(); - -if (isset($_POST["updateRules"])) { - header("Content-Type: text/plain"); - - if (!isset($_POST['payload'])) { - header("Location: /-/rules"); - die(); - } - - foreach ($_POST['payload'] as $index => $rule) { - if (!isset($rule["name"]) || !isset($rule["content"]) && !is_numeric($index)) { - header("Location: /-/rules"); - die(); - } - - if (trim($rule["name"]) === "") { - unset($_POST["payload"][$index]); - continue; - } - - if (!isset($rule["approved"])) $rule["approved"] = []; - if (isset($rule["approved"][0])) $rule["approved"][0] = true; else $rule["approved"][0] = false; - if (isset($rule["approved"][1])) $rule["approved"][1] = true; else $rule["approved"][1] = false; - - $_POST["payload"][$index] = $rule; - } - - file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/rules/rules.json", json_encode($_POST["payload"])); - file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/rules.json", "{}"); - createJob("RefreshCache", []); - - header("Location: /-/rules"); - die(); -} - -require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/components/header.inc'; -if (!file_exists($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/rules.json")) file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/rules.json", "{}"); -$cache = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/cache/rules.json"), true); - -?> - -
-
-
-

Rules

-

Edit rules

- -
- The rules system will be removed on May 2nd 2023 at midnight UTC. This page will not be accessible anymore. If there is any data you want to keep, ask Raindrops System for a copy of the rules database. -
- - - - $rule): $index++; ?> -

- Rule : ", ">", $rule["name"])) ?> - - Unapproved - -

- -
- This rule has not yet been approved. All rules need to be approved by the leaders from both systems. This rule is still missing approval from $item) { - echo($item); - if ($index < count($list) - 2) { - echo(", "); - } else if ($index < count($list) - 1) { - echo(" and "); - } - } - - ?>. -
- -
-

text(str_replace("<", "<", str_replace(">", ">", $rule["content"]))) ?>

-
- - -
-
- - - - - - - - - - diff --git a/pages/schedules.inc b/pages/schedules.inc index 04081fe..55f7670 100644 --- a/pages/schedules.inc +++ b/pages/schedules.inc @@ -3,9 +3,6 @@ require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; global $isLoggedIn; global $lang; global $pages; global $app; require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/components/header.inc'; global $readOnly; global $isNormallyLoggedIn; -require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/composer/vendor/autoload.php'; -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/composer/ical/ical.php"; - ?> - - - -
-
-
"> - -
- - Error: The requested toy () was not found, it may have been deleted or has never existed. -
- - - -
- - Success: The toy with ID has been successfully deleted. -
- - - - -

- - Back -

- -

- Edit ยท - Unverified - - Underwater - - Outside of water - - Underwater - Outside of water - -

- -
2fr !important; grid-gap: 20px;"> - -
- " style="width: 100%; max-height: 100vh;"> -
- -
- - - ", strip_tags($selected["description"]))); ?> - -

No description provided for this toy. Enter edit mode to add a description to this toy.

- - -
- -
- -
3fr 1fr6fr 1fr !important; grid-gap: 20px;">
- Usage:
- - 1) echo("
    "); - - foreach ($lines as $line) { - if (count($lines) > 1) echo("
  • "); - - $parts = explode(":", $line); - - if (count($parts) > 1 && strlen($parts[0]) < 30) { - $p0 = $parts[0]; array_shift($parts); - echo(replaceKeyWords("" . $p0 . ":" . implode(":", $parts))); - } else { - echo(replaceKeyWords(implode(":", $parts))); - } - - if (count($lines) > 1) echo("
  • "); - } - - if (count($lines) > 1) echo("
"); - - ?> - -

No usage provided for this toy. Enter edit mode to add usage information to this toy.

- -
- - Instructions to obtain in real life:
- - - -

This toy is obtainable in real life, but no instructions are provided.This toy is not obtainable in real life.

- - -
- -
- " style="width: 100%; max-height: 100vh;"> -
- -
- - -
- -

Similar toys

-
- $action["id"], - "water" => $action["water"], - "ponies" => $action["ponies"], - "sexual" => $action["sexual"], - "description" => $action["description"] - ]; - } - - foreach ($names as $name => $data) { - $namesByDistance[] = [ - "name" => $name, - "distance" => levenshtein($currentName, $name), - "id" => $data["id"], - "description" => $data["description"], - "water" => $data["water"], - "ponies" => $data["ponies"], - "sexual" => $data["sexual"] - ]; - } - - uasort($namesByDistance, function ($a, $b) use ($selected) { - return $a["distance"] - $b["distance"]; - }); - - foreach ($namesByDistance as $item) { - echo(""); - } - - $index = 0; - foreach ($namesByDistance as $item): if ($index < 3): - ?> - - -
- - -
- - - -

Toys database

- -

toys 0): ?> ( incomplete)

- - - - - -
- -
-
-

Not finding what you are looking for? Add a toy.

-
- - - - - - -
-
- - - - - - - \ No newline at end of file -- cgit