This repository has been archived by the owner on May 21, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathadminpanel.php
executable file
·112 lines (110 loc) · 2.5 KB
/
adminpanel.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
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
<style type="text/css">
<!--
.top-bar{
position: fixed;
top: 0;
left: 0;
width: 100%;
z-index: 5050;
background-color: #fafafb;
border: 1px solid #e2e2e2;
box-shadow: 0 0 5px #888;
height: 50px;
box-sizing: border-box;
font-family: Arial,"Helvetica Neue",Helvetica,sans-serif;
border-top: 3px solid #4CAF50;
border-bottom: 1px solid lightgrey;
}
.dropdown {
position: relative;
display: inline-block;
}
.dropdown-content {
display: none;
position: absolute;
background-color: #f1f1f1;
max-width: 95px;
overflow: auto;
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
z-index: 1;
}
.dropdown-content a {
color: solid black;
padding: 12px 16px;
text-decoration: none;
display: block;
}
.dropdown a:hover {background-color: #ddd;}
.dropbutton {
background-color: #4CAF50;
color: white;
padding: 11px;
font-size: 11px;
border: none;
cursor: pointer;
font-family:'Trebuchet MS', sans-serif;
border-radius: 5%;
}
.addq{
background-color: #4CAF50;
color: white;
padding: 11px;
font-size: 11px;
border: none;
cursor: pointer;
font-family:'Trebuchet MS', sans-serif;
border-radius: 5%;
}
.addq:hover{
background-color: #833AB4;
}
.dropd {
position: relative;
display: inline-block;
}
.dropd-content {
display: none;
position: absolute;
background-color: #f1f1f1;
max-width: 90px;
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
z-index: 1;
}
.dropd-content a {
color: black;
padding: 12px 16px;
text-decoration: none;
display: block;
}
.dropd-content a:hover {background-color: #ddd;}
.dropd:hover .dropd-content {display: block;}
.dropd:hover .dropbutton {background-color: #833AB4;}
.show {display: block;}
-->
</style>
<script type="text/javascript">
function redirect() { alert('Login First');
window.location.href = 'index.php';
};
</script>
<div class="top-bar">
<?php
if (session_status() == PHP_SESSION_NONE){
echo "<div style=\"position: absolute; top:8%;right:3%;\" class=\"dropd\">
<button class=\"dropbutton\"> Admin </button>
<div id=\"mydropd\" class=\"dropd-content\">
<a href=\"index.php\">SignIn</a>
<a href=\"signup.php\">SignUp</a>
</div>
</div>";
}
else{ echo "<div style=\"position: absolute; top:8%;right:3%;\" class=\"dropd\">
<button class=\"dropbutton\"> Admin </button>
<div id=\"mydropd\" class=\"dropd-content\">
<a href=\"adminhome.php\">Home</a>
<a href=\"signout.php\">LogOut</a>
</div>
</div>"; }
?>
</div>
</table>