fix: index.php

This commit is contained in:
Matthew Florentino 2025-11-27 09:21:19 +07:00
parent 6c503fe010
commit dda9cf29f6
2 changed files with 12 additions and 1 deletions

11
src/logout.php Normal file
View File

@ -0,0 +1,11 @@
<?php
session_start();
unset($_SESSION['loggedin']);
unset($_SESSION['username']);
unset($_SESSION['id']);
$_SESSION['flash'] = "Logout berhasil!";
header("Location: index.php");
exit();

View File

@ -27,7 +27,7 @@ session_start();
<a data-aos="zoom-out" data-aos-duration="2000" href="src/game/thirdperson.html">Game Start</a>
<a data-aos="zoom-out" data-aos-duration="2000" href="leaderboard.php">leaderboard</a>
<a data-aos="zoom-out" data-aos-duration="2000" href="">Credit</a>
<a data-aos="zoom-out" data-aos-duration="2000" href="logout.php">Exit</a>
<a data-aos="zoom-out" data-aos-duration="2000" href="logout.php" >Exit</a>
</div>
</div>
<script src="https://unpkg.com/aos@2.3.1/dist/aos.js"></script>