-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfooter.php
32 lines (28 loc) · 892 Bytes
/
footer.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
<?php
// Initialize the session
//session_start();
$current_status = 'Sign Out of Your Account';
$link_address = 'logout.php';
// Check if the user is logged in, if not then redirect him to login page
if(!isset($_SESSION["loggedin"]) || $_SESSION["loggedin"] !== true){
$current_status = 'Sign Into Your Account';
$link_address = 'login.php';
//header("location: login.php");
//exit;
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Welcome</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.css">
<style type="text/css">
body{ font: 14px sans-serif; text-align: center; }
</style>
</head>
<footer>
<a href="<?php echo $link_address;?>" class="btn btn-danger"><?php echo $current_status; ?> </a>
© sinkosi 2019
</footer>
</html>