-
Notifications
You must be signed in to change notification settings - Fork 0
/
welcome.php
139 lines (127 loc) · 3.72 KB
/
welcome.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
<!DOCTYPE html>
<html>
<head>
<title>Welcome</title>
<style>
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600&display=swap');
*{
font-family: 'Poppins', sans-serif;
margin:0; padding:0;
box-sizing: border-box;
outline: none;
border:none;
text-decoration: none;
align-items:center;
justify-content: center;
}
.header{
position: fixed;
top: 0;
left: 0;
width: 100%;
padding: 16px 10%;
background: transparent;
display: flex;
justify-content: space-between;
align-items: center;
z-index: 100;
box-shadow: 0 5px 10px rgba(0,0,0,.1);
}
.logo{
font-size: 18px;
color: #367588;
text-decoration: none;
font-weight: 600;
}
body{
background: #333;
align-items:center;
justify-content: center;
background: url('image-med-app-4.jpg') no-repeat;
background-size: auto;
}
.container {
border-radius: 7px;
box-shadow: 0 5px 10px rgba(0,0,0,.1);
min-height: 70vh;
display: flex;
justify-content: center;
align-items: center;
padding:20px;
padding-bottom: 60px;
background: #fff;
text-align: center;
width: 500px;
margin:auto;
margin-top: 100px;
}
.container .content h3{
font-size: 30px;
color:#333;
}
.username {
font-size: 20px;
font-weight: bold;
margin-bottom: 20px;
}
.button-container {
margin-top: 40px;
}
.button-container button{
/*width: 200px;
margin-bottom: 20px;
display: block;
background: #fbd0d9;
color:crimson;
text-transform: capitalize;
font-size: 13px;
cursor: pointer;
padding:10px 30px;*/
width: 270px;
display: block;
background: #A4DDED;
color:#002147;
text-transform: capitalize;
font-size: 20px;
cursor: pointer;
padding:10px 30px;
margin-top: 40px;
border-radius: 5px;
}
.button-container button:hover{
background: #002147;
color:#A4DDED;
}
</style>
</head>
<body>
<header class="header">
<a href='logout.php' class="logo">LOGOUT</a>
</header>
<div class="container">
<div class="content">
<h3>Welcome</h3>
<?php
// Establish database connection
@include "config.php";
session_start();
// Retrieve username from the database
$userId = $_SESSION['user_name'];
/*$sql = "SELECT username FROM users WHERE username = '$userId'";
$result = $conn->query($sql);
if ($result->num_rows > 0) {
$row = $result->fetch_assoc();
$user_name = $row['username'];
}*/
echo "<div class='username'>Welcome, " . $userId . "</div>";
$conn->close();
?>
<div class="button-container">
<button onclick="window.location.href='medicine form/index.php'">Medicine Schedule</button>
<button onclick="window.location.href='graphs/newwChamo.php'">Patient Details</button>
</div>
<!--<div><a href='logout.php'>Logout</a></div>-->
</div>
</div>
</body>
</html>