diff options
author | Minteck <contact@minteck.org> | 2022-10-10 20:51:39 +0200 |
---|---|---|
committer | Minteck <contact@minteck.org> | 2022-10-10 20:51:39 +0200 |
commit | 108525534c28013cfe1897c30e4565f9893f3766 (patch) | |
tree | dd3e5132971f96ab5f05e7f3f8f6dbbf379a19bd /api/fronter.php | |
parent | 2162eaa06f7e4764eb3dcfe130ec2c711d0c62ab (diff) | |
download | pluralconnect-108525534c28013cfe1897c30e4565f9893f3766.tar.gz pluralconnect-108525534c28013cfe1897c30e4565f9893f3766.tar.bz2 pluralconnect-108525534c28013cfe1897c30e4565f9893f3766.zip |
Update
Diffstat (limited to 'api/fronter.php')
-rw-r--r-- | api/fronter.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/api/fronter.php b/api/fronter.php index f962625..0dd6e99 100644 --- a/api/fronter.php +++ b/api/fronter.php @@ -1,6 +1,6 @@ <?php -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/session.php"; global $isLoggedIn; +require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/session.inc"; global $isLoggedIn; if (!$isLoggedIn) header("Location: /-/login") and die(); $system = $_GET['s'] ?? null; @@ -18,7 +18,7 @@ if (!isset($type) || trim($type) === "") if (!isset($date) || trim($date) === "" || strlen($date) !== 10 || !preg_match("/[\d-]/i", $date)) header("Location: /?error=Date not found") and die(); -$list = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/$system-planner.json"), true); +$list = json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/planner/$system.json"), true); function moveElement(&$array, $a, $b) { $out = array_splice($array, $a, 1); @@ -105,6 +105,6 @@ switch ($type) { break; } -file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/$system-planner.json", json_encode($list)); +file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/planner/$system.json", json_encode($list)); die();
\ No newline at end of file |