-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathheader.php
More file actions
44 lines (34 loc) · 1.61 KB
/
header.php
File metadata and controls
44 lines (34 loc) · 1.61 KB
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
<?php
include("config.php");
/* to debug uncomment: ini_set('display_errors', 1); */
?>
<!doctype html>
<html>
<head>
<title>Scriptum - write your mind</title>
<meta charset = "UTF-8">
<link rel="icon" href="media/logo.png" type="image/png">
<meta name="viewport" content="width = device-width, initial-scale = 1.0">
<link rel="stylesheet" type="text/css" href="style.css">
<link href="https://fonts.googleapis.com/css?family=Oswald|Playfair+Display" rel="stylesheet" type="text/css">
<!-- <script src="https://cdn.jsdelivr.net/npm/moment@2/moment.min.js"></script> -->
<!-- JSDelivr down? Try this: <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.22.2/moment.min.js"></script> -->
</head>
<body>
<header>
<a href = "index.php" class = "headerTitle">
<img class = "logo" title = "logo" alt = "logo" src = "media/logo.png"></img>
Scriptum
</a>
<nav>
<?php
if (isset($_SESSION["user"])) {
echo "<div id = 'navBig'><a href = 'settings.php' class = 'navLink'>Settings</a><a href = 'logsign.php?logout=true&token=" . $_SESSION['userToken'] . "' class = 'navLink'>Logout</a></div>";
echo "<div id = 'navSmall'><a title = 'settings' alt = 'settings' href = 'settings.php' class = 'navLink'><img class = 'headIcon' src = 'settings.png'></a><a title = 'logout' alt = 'logout' href = 'logsign.php?logout=true&token=" . $_SESSION['userToken'] . "' class = 'navLink'><img class = 'headIcon' src = 'logout.png'></a></div>";
}
else {
echo "<a href = 'login.php' class = 'navLink'>Login</a><a href = 'signup.php' class = 'navLink'>Signup</a>";
}
?>
</nav>
</header>