-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdashboard.php
executable file
·52 lines (51 loc) · 1.39 KB
/
dashboard.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
<?php
if(!isset($_GET['v']))
header("Location: ./dashboard.php?v=courses");
session_start();
if(!file_exists("./config.inc.php"))
{
header("Location: ./install.php");
}
require "config.inc.php";
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<?php if(!isset($_SESSION['admin'])) { ?>
<meta http-equiv="refresh" content="0;url=./login.php">
<?php } ?>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Admin Dashboard - Hostel Allotment - <?php echo $glInstitute; ?></title>
<link rel="stylesheet" href="main.css" type="text/css" media="screen" />
<script language="javascript" src="script.js" type="text/javascript" ></script>
</head>
<body>
<div id="header" class="hideP">
<?php include "./includes/header.php"; ?>
</div>
<div align="center">
<h2 class="hideP" id="instituteName"><?php
echo $glInstitute; ?></h2>
<h2 class="hideP">Hostel Allotment</h2>
<?php if(isset($_GET['v']) && $_GET['v'] == 'hostel') {
?>
<div id="doubleWrapper">
<?php
}
else {
echo "<div id=\"wrapper\">";
}
?>
<h2 align="center">Admin Dashboard</h2>
<?php
switch($_GET['v']) {
case 'courses';
include "./pages/dashCourses.php";
break;
case 'hostel';
include "./pages/dashHostel.php";
break;
}
?>
</div>
</div></body></html>