initial draft of the achievement system

This commit is contained in:
marko
2020-10-28 14:02:40 +01:00
parent c83c71dab8
commit 9e32b83c90
16 changed files with 440 additions and 0 deletions

16
homepage/machs/auth.php Normal file
View File

@@ -0,0 +1,16 @@
<?php
session_start();
// Falls der serverseitige Logincookie nicht gesetzt ist,
// leite zur loginSeite weiter
if (empty($_SESSION['login'])) {
header('Location: login.php', TRUE, 301);
exit;
} else {
$login_status =
"<div style=\"border: 1px solid black\">".
"Datum: ".date("Y-m-d")."<br />".
"Angemeldet als <strong>".htmlspecialchars($_SESSION['user']['username'])."</strong> angemeldet.<br />".
"<a href=\"logout.php\">Sitzung beenden</a>".
"</div>";
}
?>