-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdashboard.php
79 lines (73 loc) · 2.32 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
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
<?php
/**
* Created by PhpStorm.
* User: Ashwini
* Date: 2/8/18
*/
//TODO: Implement Admin Section
$title = 'Dashboard';
require('config/db.php');
include("auth.php"); //include auth.php file on all secure pages
require('layout/header.php');
$role = $_SESSION['role'];
$blood_group = $_SESSION['blood_group'];
?>
<div class="row">
<div class="col-md-4">
<div class="card" style="width: 20rem;">
<img class="card-img-top" src="asset/life.jpg" alt="Card image cap" >
<div class="card-block">
<div style="color: red">WELCOME</div>
<h4 class="card-title">
<?php
echo htmlspecialchars($_SESSION['name'], ENT_QUOTES);
?>
</h4>
<p class="card-text">
Blood Group:
<strong>
<?php
echo $blood_group;
?>
</strong><br>
Email:
<strong>
<?php
echo $_SESSION['email'];
?>
</strong>
</p>
</div>
</div><br>
<div class="card" style="width: 20rem;">
<h4 class="card-header text-center">Notes</h4>
<div class="card-block">
<h4 class="card-title">Words from Creator</h4>
<p class="card-text">This projest is created for the demonstration
purpose by Ashwini Gupta <a href="https://www.twitter.com/fnlsg">@fnlsg</a>.<br>
- Have following features:
</p>
<ul>
<li>Registration</li>
<li>Search and Request</li>
<li>Add blood to Bank</li>
</ul>
</div>
</div>
</div>
<div class="col-md-8 text-center">
<p class="lead">Important Links</p>
<hr>
<?php
if ($role == 'Hospital'){
require('dashboard/dashboard_hospital.php');
} elseif ($role == 'User'){
require('dashboard/dashboard_user.php');
}
?>
</div>
</div>
<?php
//include header template
require('layout/footer.php');
?>