Added some more stuff to the header while I put off fixing the registration thing
This commit is contained in:
parent
a272c7d46b
commit
8a3fa80a70
|
@ -1,8 +1,21 @@
|
|||
<?php
|
||||
// Load in display variables
|
||||
$title = $title ?? '~chan';
|
||||
?>
|
||||
|
||||
// Start handing session stuff
|
||||
session_start();
|
||||
?>
|
||||
<!--
|
||||
# - # - # - # - # - # - # - # - # - # - # - # - # - # - #
|
||||
# #
|
||||
# tildechan #
|
||||
# - #
|
||||
# by ~stilbruch #
|
||||
# - #
|
||||
# https://github.com/TheStilbruch/tildechan #
|
||||
# #
|
||||
# - # - # - # - # - # - # - # - # - # - # - # - # - # - #
|
||||
-->
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" href="/css/main.css">
|
||||
|
@ -25,9 +38,24 @@ $title = $title ?? '~chan';
|
|||
<span>
|
||||
<b>links:</b> (
|
||||
<a href="/">home</a>
|
||||
/
|
||||
<a href="/login.php">login</a>
|
||||
)
|
||||
</span>
|
||||
<span>
|
||||
<b>profile:</b> (
|
||||
<?php
|
||||
if ($_SESSION['logged_in'] == 1) {
|
||||
// I just decided to echo everything out here since the <?php ?\> syntax was ugly
|
||||
echo "<a href=\"/profile.php\">profile</a>";
|
||||
echo " / ";
|
||||
echo "<a href=\"logout.php\">log out</a>";
|
||||
echo " )";
|
||||
} else {
|
||||
echo "<a href=\"/register.php\">register</a>";
|
||||
echo " / ";
|
||||
echo "<a href=\"/login.php\">login</a>";
|
||||
echo " )";
|
||||
}
|
||||
?>
|
||||
</span>
|
||||
</div>
|
||||
<div class="main">
|
||||
|
|
Loading…
Reference in New Issue