-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSettings.php
55 lines (50 loc) · 1.74 KB
/
Settings.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?php
require_once 'Include/Load.php';
$session = App::getSession();
$link = App::getDatabase();
$user = App::getUser();
$user->restrict();
?>
<?php require_once 'Include/Header.php'; ?>
<div id="navBar">
<h2>SETTINGS</h2>
<a href="ChangeUsername.php" class="nav-links">
<span class="material-symbols-outlined">badge</span>
<span class="icon-text">Change Username</span>
</a>
<a href="ChangePassword.php" class="nav-links">
<span class="material-symbols-outlined">password</span>
<span class="icon-text">Change Password</span>
</a>
<?php if ($session->getKey('mode') == null): ?>
<a href="SetMode.php?mode=1" class="nav-links">
<span class="material-symbols-outlined">light_mode</span>
<span class="icon-text">Blue Mode</span>
</a>
<?php else: ?>
<a href="SetMode.php" class="nav-links">
<span class="material-symbols-outlined">dark_mode</span>
<span class="icon-text">Red Mode</span>
</a>
<?php endif; ?>
<a href="SetBirthDate.php" class="nav-links">
<span class="material-symbols-outlined">event</span>
<span class="icon-text">Set Birth Date</span>
</a>
<a href="#" class="nav-links" id="deleteAccount">
<span class="material-symbols-outlined">delete</span>
<span class="icon-text">Delete Account</span>
</a>
</div>
<script>
let deleteAccountLink = document.getElementById('deleteAccount');
deleteAccountLink.addEventListener('click', function (evt) {
evt.preventDefault();
if (window.confirm('You are deleting your Account')){
window.location = 'DeleteAccount.php';
}
})
</script>
<?php require_once 'Include/Mode.php' ?>
</body>
</html>