-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathadmin.php
More file actions
131 lines (128 loc) · 4.53 KB
/
Copy pathadmin.php
File metadata and controls
131 lines (128 loc) · 4.53 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<?php
session_start();
include "koneksi.php";
//check jika belum ada user yang login arahkan ke halaman login
if (!isset($_SESSION['username'])) {
header("location:login.php");
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>My Daily Journal | Admin</title>
<link rel="icon" href="img/logo.png" />
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.1/font/bootstrap-icons.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN"
crossorigin="anonymous"
/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.1/jquery.min.js"></script>
<style>
html {
position: relative;
min-height: 100%;
}
body {
margin-bottom: 100px; /* Margin bottom by footer height */
}
footer {
position: absolute;
bottom: 0;
width: 100%;
height: 100px; /* Set the fixed height of the footer here */
}
</style>
</head>
<body>
<!-- nav begin -->
<nav class="navbar navbar-expand-sm bg-body-tertiary sticky-top bg-danger-subtle">
<div class="container">
<a class="navbar-brand" target="_blank" href=".">My Daily Journal</a>
<button
class="navbar-toggler"
type="button"
data-bs-toggle="collapse"
data-bs-target="#navbarSupportedContent"
aria-controls="navbarSupportedContent"
aria-expanded="false"
aria-label="Toggle navigation"
>
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav ms-auto mb-2 mb-lg-0 text-dark">
<li class="nav-item">
<a class="nav-link" href="admin.php?page=dashboard">Dashboard</a>
</li>
<li class="nav-item">
<a class="nav-link" href="admin.php?page=article">Article</a>
</li>
<li class="nav-item">
<a class="nav-link" href="admin.php?page=gallery">Gallery</a>
</li>
<li class="nav-item">
<a class="nav-link" href="index.php"><b>Homepage</b></a>
</li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle text-danger fw-bold" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false">
<?= $_SESSION['username']?>
</a>
<ul class="dropdown-menu">
<li><a class="dropdown-item" href="logout.php">Logout</a></li>
<li><a class="dropdown-item" href="admin.php?page=profile">Profile <?= $_SESSION['username']?> </a></li>
</ul>
</li>
</ul>
</div>
</div>
</nav>
<!-- nav end -->
<!-- content begin -->
<section id="content" class="p-5">
<div class="container">
<?php
if(isset($_GET['page'])){
?>
<h4 class="lead display-6 pb-2 border-bottom border-danger-subtle"><?= ucfirst($_GET['page'])?></h4>
<?php
include($_GET['page'].".php");
}else{
?>
<h4 class="lead display-6 pb-2 border-bottom border-danger-subtle">Dashboard</h4>
<?php
include("dashboard.php");
}
?>
</div>
</section>
<!-- content end -->
<!-- footer begin -->
<footer id="footer" class="text-center p-3 bg-danger-subtle" style="margin-bottom: 0%;" >
<div>
<a href="https://www.instagram.com/udinusofficial"
><i class="bi bi-instagram h2 p-2 text-dark"></i
></a>
<a href="https://twitter.com/udinusofficial"
><i class="bi bi-twitter h2 p-2 text-dark"></i
></a>
<a href="https://wa.me/+62895384205321"
><i class="bi bi-whatsapp h2 p-2 text-dark"></i
></a>
</div>
<div class="bg-danger-subtle">Audi Husen Mustofa © 2023</div>
</footer>
<!-- footer end -->
<script
src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js"
integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL"
crossorigin="anonymous"
></script>
</body>
</html>