-
Notifications
You must be signed in to change notification settings - Fork 1
/
bookroom.php
186 lines (186 loc) · 4.69 KB
/
bookroom.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
<!DOCTYPE html>
<html>
<head>
<title>User Room Book</title>
</head>
<style>
body {
margin: 0;
background: #f2f2f2;
}
table {
font-size: 22px;
}
#td1
{
background-color: rgba(09,41,98,0.9);
color: white;
border: 10px;
margin-top: -10px;
padding: 10px;
text-align: center;
}
td {
text-align: left;
}
th {
font-weight: bold;
text-align: left;
}
ul {
list-style-type: none;
margin: 0;
padding: 0;
width: 22%;
font-size: 24px;
background-color: rgba(09,41,98,0.9);
text-decoration: none;
position: fixed;
height: 100%;
overflow: auto;
}
li {
color: white;
}
li a {
display: block;
color: white;
padding: 8px 16px;
text-decoration: none;
}
li a:active {
background-color: #e6b800;
color: white;
text-decoration: underline;
}
li a:hover {
background-color: #e6b800;
color: white;
text-decoration: underline;
}
.basic_box {
border: 1px solid #ccc;
border-radius: 15px;
margin: auto;
width: 600px;
padding: 50px;
box-shadow: 0 10px 20px rgba(0,0,0,0.19);
}
</style>
<body>
<?php
$conn = new mysqli("localhost","root","", "iwp");
if($conn->connect_error)
{
die("Connection failed: ".$conn->connect_error);
}
$sql = "SELECT * from temp_session";
$result=mysqli_query($conn, $sql);
$row=mysqli_fetch_row($result); ?>
<table style="width: 100%;">
<tr>
<td id="td1" style="padding: 10px; font-size: 48px;">THE <p style="color: #e6b800; display: inline;">DELUXE</p> HOTEL</td>
<td id="td1" style="font-size: 25px; text-align: right;">Hello, <?php echo $row[2]; ?></td>
</tr>
</table>
<ul>
<li><a href="user_view.php">My Info</a></li>
<li><a href="bookroom.php">Book A Room</a></li>
<li><a href="user_room_status.php">Show Booking Status</a></li>
<li><a href="user_payment.php">Payment</a></li>
<li><a href="user_booking_history.php">Booking History</a></li>
<li><a href="index.php">Logout</a></li>
</ul>
<div style="margin-left:25%;padding:1px 16px;height:1000px;">
<p style="margin-left: 10%; margin-top: 5%; font-size: 28px;"></p>
<table class="basic_box">
<tr>
<th colspan="3"><p style="font-size: 28px; text-align: center; text-decoration: underline;">Room Details</p></th>
</tr>
<tr>
<th>Room Type</th>
<th>Number of beds</th>
<th>Price</th>
</tr>
<tr>
<td>Single Bedded</td>
<td>1</td>
<td>1000</td>
</tr>
<tr>
<td>Double Bedded</td>
<td>2</td>
<td>1800</td>
</tr>
<tr>
<td>Four Bedded</td>
<td>4</td>
<td>3000</td>
</tr>
</table><br><br>
<form class="basic_box" action="bookroom1.php" method="post">
<table>
<br><br>
<tr>
<td style="text-align: left;">Select room type:</td>
<td style="text-align: left;">
<select name="rooms" required>
<option value="">Select</option>
<option value="Single bed">Single bedded</option>
<option value="Double bed">Double bedded</option>
<option value="Four bed">Four bedded</option>
</select>
</td>
</tr>
<tr>
<td style="text-align: left;">Enter check-in date:</td>
<td style="text-align: left;">
<input type="date" name="checkin">
</td>
</tr>
<tr>
<td style="text-align: left;">Enter check-out date:</td>
<td style="text-align: left;">
<input type="date" name="checkout">
</td>
</tr>
</table>
<table>
<br>
<tr>
<th>Features</th>
<th>Service Cost per day</th>
</tr>
<tr>
<td><input type="checkbox" name="ac" value="on">AC</td>
<td style="text-align: center;">300</td>
</tr>
<tr>
<td><input type="checkbox" name="breakfast" value="on">Breakfast</td>
<td style="text-align: center;">150</td>
</tr>
<tr>
<td><input type="checkbox" name="lunch" value="on">Lunch</td>
<td style="text-align: center;">300</td>
</tr>
<tr>
<td><input type="checkbox" name="snacks" value="on">Evening Snacks</td>
<td style="text-align: center;">120</td>
</tr>
<tr>
<td><input type="checkbox" name="dinner" value="on">Dinner</td>
<td style="text-align: center;">250</td>
</tr>
<tr>
<td><input type="checkbox" name="swimming" value="on">Swimming Pool Access</td>
<td style="text-align: center;">300</td>
</tr>
<tr><br></tr>
<tr>
<td colspan="2" style="text-align: center;"><input type="submit" value="Submit"></td>
</tr>
</table>
</form>
</div>
</body>
</html>