-
Notifications
You must be signed in to change notification settings - Fork 115
/
profile.php
326 lines (306 loc) · 11.5 KB
/
profile.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
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
<?php
require 'includes/config.inc.php';
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>User Profile</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="keywords" content="Consultancy Profile Widget Responsive web template, Bootstrap Web Templates, Flat Web Templates, Android Compatible web template,
Smartphone Compatible web template, free webdesigns for Nokia, Samsung, LG, SonyEricsson, Motorola web design" />
<script type="application/x-javascript"> addEventListener("load", function() { setTimeout(hideURLbar, 0); }, false);
function hideURLbar(){ window.scrollTo(0,1); } </script>
<!-- js -->
<script src="web_profile/js/jquery-2.1.3.min.js" type="text/javascript"></script>
<script type="text/javascript" src="web_profile/js/sliding.form.js"></script>
<!-- //js -->
<link href="web_profile/css/style.css" rel="stylesheet" type="text/css" media="all" />
<link rel="stylesheet" href="web_profile/css/font-awesome.min.css" />
<link rel="stylesheet" href="web_profile/css/smoothbox.css" type='text/css' media="all" />
<link href="//fonts.googleapis.com/css?family=Pathway+Gothic+One" rel="stylesheet">
<link href='//fonts.googleapis.com/css?family=Open+Sans:400,300,300italic,400italic,600,600italic,700,700italic,800,800italic' rel='stylesheet' type='text/css'>
<script type="application/x-javascript">
addEventListener("load", function () {
setTimeout(hideURLbar, 0);
}, false);
function hideURLbar() {
window.scrollTo(0, 1);
}
</script>
<!--// Meta tag Keywords -->
<link href="web_home/css_home/slider.css" type="text/css" rel="stylesheet" media="all">
<!-- css files -->
<link rel="stylesheet" href="web_home/css_home/bootstrap.css"> <!-- Bootstrap-Core-CSS -->
<link rel="stylesheet" href="web_home/css_home/style.css" type="text/css" media="all" /> <!-- Style-CSS -->
<link rel="stylesheet" href="web_home/css_home/fontawesome-all.css"> <!-- Font-Awesome-Icons-CSS -->
<!-- //css files -->
<!-- testimonials css -->
<link rel="stylesheet" href="web_home/css_home/flexslider.css" type="text/css" media="screen" property="" /><!-- flexslider css -->
<!-- //testimonials css -->
<!-- web-fonts -->
<link href="//fonts.googleapis.com/css?family=Poiret+One&subset=cyrillic,latin-ext" rel="stylesheet">
<!-- //web-fonts -->
</head>
<body>
<!-- banner -->
<div class="banner" id="home">
<div class="cd-radial-slider-wrapper">
<!--Header-->
<header>
<div class="container agile-banner_nav">
<nav class="navbar navbar-expand-lg navbar-light bg-light">
<h1><a class="navbar-brand" href="home.php">NITC <span class="display"></span></a></h1>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse justify-content-center" id="navbarSupportedContent">
<ul class="navbar-nav ml-auto">
<li class="nav-item active">
<a class="nav-link" href="home.php">Home <span class="sr-only">(current)</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="services.php">Hostels</a>
</li>
<li class="nav-item">
<a class="nav-link" href="contact.php">Contact</a>
</li>
<li class="dropdown nav-item">
<!--<a href="#" class="dropdown-toggle nav-link" data-toggle="dropdown"><?php echo $_SESSION['roll']; ?>
<b class="caret"></b>
</a>
<ul class="dropdown-menu agile_short_dropdown">
<li>
<a href="profile.php">My Profile</a>
</li>-->
<li>
<a href="includes/logout.inc.php" class="nav-link">Logout</a>
</li>
</ul>
</li>
</ul>
</div>
</nav>
</div>
</header>
<!--Header-->
<br><br><br><br><br>
<div class="main">
<div id="navigation" style="display:none;" class="w3_agile">
<ul>
<li class="selected">
<a href="#"><i class="fa fa-list-ul" aria-hidden="true"></i><span>Info</span></a>
</li>
<li>
<a href="#"><i class="fa fa-folder" aria-hidden="true"></i><span>Hostel</span></a>
</li>
<li>
<a href="#"><i class="fa fa-envelope" aria-hidden="true"></i><span>Contact</span></a>
</li>
</ul>
</div>
<div id="wrapper" class="w3ls_wrapper w3layouts_wrapper">
<div id="steps" style="margin:0 auto;" class="agileits w3_steps">
<form id="formElem" name="formElem" action="#" method="post" class="w3_form w3l_form_fancy">
<fieldset class="step agileinfo w3ls_fancy_step">
<legend>Personal Info</legend>
<div class="abt-agile">
<div class="abt-agile-left">
</div>
<div class="abt-agile-right">
<h3><?php echo $_SESSION['fname']." ".$_SESSION['lname']; ?></h3>
<h5>Student</h5>
<ul class="address">
<li>
<ul class="address-text">
<li><b>Roll No </b></li>
<li>: <?php echo $_SESSION['roll']; ?></li>
</ul>
</li>
<li>
<ul class="address-text">
<li><b>PHONE </b></li>
<li>: <?php echo $_SESSION['mob_no']; ?></li>
</ul>
</li>
<li>
<ul class="address-text">
<li><b>DEPT </b></li>
<li>: <?php echo $_SESSION['department']; ?></li>
</ul>
</li>
<li>
<ul class="address-text">
<li><b>YEAR OF STUDY </b></li>
<li>: <?php echo $_SESSION['year_of_study']; ?></li>
</ul>
</li>
</ul>
</div>
<div class="clear"></div>
</div>
</fieldset>
<fieldset class="step agileinfo w3ls_fancy_step">
<legend>Hostel Info</legend>
<div class="abt-agile">
<div class="abt-agile-left-hostel">
</div>
<div class="abt-agile-right">
<h3><?php echo $_SESSION['fname']." ".$_SESSION['lname']; ?></h3>
<h5>Student</h5>
<ul class="address">
<li>
<ul class="address-text">
<li><b>HOSTEL </b></li>
<?php
$hostelId = $_SESSION['hostel_id'];
if($hostelId == NULL){
$hostelName = 'None';
}
else {
$sql = "SELECT * FROM Hostel WHERE Hostel_id = '$hostelId'";
$result = mysqli_query($conn, $sql);
if($row = mysqli_fetch_assoc($result)){
$hostelName = $row['Hostel_name'];
}
else {
echo "<script type='text/javascript'>alert('Foreign Key Error-hostenName!!')</script>";
}
}
?>
<li>: <?php echo $hostelName; ?></li>
</ul>
</li>
<li>
<ul class="address-text">
<li><b>ROOM NO </b></li>
<?php
$roomId = $_SESSION['room_id'];
if($hostelId == NULL || $roomId == NULL){
$roomNo = 'None';
}
else {
$sql = "SELECT * FROM Room WHERE Room_id = '$roomId'";
$result = mysqli_query($conn, $sql);
if($row = mysqli_fetch_assoc($result)){
$roomNo = $row['Room_No'];
}
else {
echo "<script type='text/javascript'>alert('Foreign Key Error-roomNo!!')</script>";
}
}
?>
<li>: <?php echo $roomNo; ?></li>
</ul>
</li>
</ul>
</div>
<div class="clear"></div>
</div>
</fieldset>
<!-- <fieldset class="step wthree">
<legend>Work</legend>
<div class="work-w3agile">
<div class="work-w3agile-top">
<div class="agileits_w3layouts_work_grid1 w3layouts_work_grid1 hover14 column">
<div class="w3_agile_work_effect">
<ul>
<li>
<a href="web_profile/images/c1.jpg" class="sb" title="Quis Nostrud Exercitation Ullamco Laboris Quis Autem Vel Eum Iure Reprehenderit">
<figure>
<img src="web_profile/images/c1.jpg" alt=" " class="img-responsive" />
</figure>
</a>
</li>
<li>
<a href="web_profile/images/c2.jpg" class="sb" title="Quis Nostrud Exercitation Ullamco Laboris Quis Autem Vel Eum Iure Reprehenderit">
<figure>
<img src="web_profile/images/c2.jpg" alt=" " class="img-responsive" />
</figure>
</a>
</li>
<li>
<a href="web_profile/images/c3.jpg" class="sb" title="Quis Nostrud Exercitation Ullamco Laboris Quis Autem Vel Eum Iure Reprehenderit">
<figure>
<img src="web_profile/images/c3.jpg" alt=" " class="img-responsive" />
</figure>
</a>
</li>
<li>
<a href="web_profile/images/c4.jpg" class="sb" title="Quis Nostrud Exercitation Ullamco Laboris Quis Autem Vel Eum Iure Reprehenderit">
<figure>
<img src="web_profile/images/c4.jpg" alt=" " class="img-responsive" />
</figure>
</a>
</li>
<li>
<a href="web_profile/images/c5.jpg" class="sb" title="Quis Nostrud Exercitation Ullamco Laboris Quis Autem Vel Eum Iure Reprehenderit">
<figure>
<img src="web_profile/images/c5.jpg" alt=" " class="img-responsive" />
</figure>
</a>
</li>
<li>
<a href="web_profile/images/c6.jpg" class="sb" title="Quis Nostrud Exercitation Ullamco Laboris Quis Autem Vel Eum Iure Reprehenderit">
<figure>
<img src="web_profile/images/c6.jpg" alt=" " class="img-responsive" />
</figure>
</a>
</li>
<div class="clear"></div>
</ul>
</div>
</div>
</div>
</div>
</fieldset>-->
<fieldset class="step agileinfo w3ls_fancy_step">
<legend>Hostel Manager Info</legend>
<div class="abt-agile">
<div class="abt-agile-left">
</div>
<div class="abt-agile-right">
<?php
$Hid = $_SESSION['hostel_id'];
$sql1 = "SELECT * FROM Hostel_Manager WHERE Hostel_id = '$Hid'";
$result1 = mysqli_query($conn, $sql1);
if($row1 = mysqli_fetch_assoc($result1)){
$hmfname = $row1['Fname'];
$hmlname = $row1['Lname'];
$hmMob = $row1['Mob_no'];
$hmemail = $row1['Email'];
}
else {
$hmfname = 'none';
$hmlname = 'none';
$hmMob = 'none';
$hmemail = 'none';
}
?>
<h3><?php echo $hmfname." ".$hmlname; ?></h3>
<h5>Admin</h5>
<ul class="address">
<li>
<ul class="address-text">
<li><b>PHONE </b></li>
<li>: <?php echo $hmMob; ?></li>
</ul>
</li>
<li>
<ul class="address-text">
<li><b>Email </b></li>
<li>: <?php echo $hmemail; ?></li>
</ul>
</li>
</ul>
</div>
<div class="clear"></div>
</div>
</fieldset>
</form>
</div>
</div>
</div>
<script type="text/javascript" src="web_profile/js/smoothbox.jquery2.js"></script>
</body>
</html>