summaryrefslogtreecommitdiff
path: root/api/cloudburst-scored.php
blob: 37acbcc59cd92c9f34d1ba86b54ec2bf38e756db (plain)
1
2
3
4
5
6
7
8
9
<?php

require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/session.php"; global $isLoggedIn;
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/score.php";
require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/bitset.php";
if (!$isLoggedIn) header("Location: /-/login") and die();

header("Content-Type: application/json");
die(json_encode(array_values(scoreOrder(json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/ynmuc-members.json"), true), "ynmuc")), JSON_PRETTY_PRINT));