-
Notifications
You must be signed in to change notification settings - Fork 3
/
index.php
158 lines (128 loc) · 5.62 KB
/
index.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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
<?php
session_start();
if(isset($_SESSION['id'])){
include 'config/connection.php';
include 'config/funcGoogleApi.php';
//page header
include 'navigation/header.php';
?>
<!-- wrapper -->
<div id="wrapper">
<!-- navbar top -->
<nav class="navbar navbar-default navbar-fixed-top" role="navigation" id="navbar">
<!-- navbar-header -->
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".sidebar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<img src="assets/img/da.png" alt="" class="img img-responsive" width="370px" height="370px" style="padding: 7px; margin-top: 5px; margin-left:7px;"/>
</div>
<!-- end navbar-header -->
<!-- navbar-top-links -->
<ul class="nav navbar-top-links navbar-right">
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
<i class="fa fa-user fa-3x"></i>
</a>
<!-- dropdown user-->
<ul class="dropdown-menu dropdown-user">
<li><a href="logout.php"><i class="fa fa-sign-out fa-fw"></i>Logout</a>
</li>
</ul>
<!-- end dropdown-user -->
</li>
<!-- end main dropdown -->
</ul>
<!-- end navbar-top-links -->
</nav>
<!-- end navbar top -->
<!-- navbar side -->
<nav class="navbar-default navbar-static-side" role="navigation">
<!-- sidebar-collapse -->
<div class="sidebar-collapse">
<!-- side-menu -->
<ul class="nav" id="side-menu">
<li>
<!-- user image section-->
<div class="user-section">
<div class="user-section-inner">
<img src="assets/img/user.jpg" alt="">
</div>
<div class="user-info">
<div><?php echo $_SESSION['nama_dosen']; ?></div>
<div class="user-text-online">
<span class="user-circle-online btn btn-success btn-circle "></span> Online
</div>
</div>
</div>
<!--end user image section-->
</li>
<li class="sidebar-search">
<!-- search section-->
<div class="input-group custom-search-form">
<input type="text" class="form-control" placeholder="Search...">
<span class="input-group-btn">
<button class="btn btn-default" type="button">
<i class="fa fa-search"></i>
</button>
</span>
</div>
<!--end search section-->
</li>
<li class="selected">
<a href="index.php"><i class="fa fa-dashboard fa-fw"></i> Dashboard</a>
</li>
<?php
if($_SESSION['level']=='kajur'){
?>
<li>
<a href="?page=formInput"><i class="fa fa-table fa-fw"></i> Input Mahasiswa( data baru )</a>
</li>
<li>
<a href="?page=listMhs"><i class="fa fa-list-alt fa-fw"></i> Data Mahasiswa</a>
</li>
<?php } ?>
<li>
<a href="?page=predict"><i class="fa fa-flask fa-fw"></i> Prediksi</a>
</li>
<li>
<a href="?page=chart"><i class="fa fa-signal fa-fw"></i> Grafik </a>
</li>
<!--<a href="?page=accuracy"><i class="fa fa-credit-card fa-fw"></i> Akurasi Prediksi </a>-->
</ul>
<!-- end side-menu -->
</div>
<!-- end sidebar-collapse -->
</nav>
<!-- end navbar side -->
<!-- page-wrapper -->
<div id="page-wrapper">
<?php
//generate get page
if(isset($_GET['page'])){
$page=htmlentities($_GET['page']);
}else{
$page="dashboard";
}
$file="$page.php";
$cek=strlen($page);
if($cek>30 || !file_exists($file) || empty($page)){
include ("dashboard.php");
}else{
include ($file);
}
?>
</div>
<!-- end page-wrapper -->
</div>
<!-- end wrapper -->
<?php
//page footer
include 'navigation/footer.php';
}else{
header('location:login.php');
}
?>