-
Notifications
You must be signed in to change notification settings - Fork 0
/
view_packages_T_pradi.php
100 lines (69 loc) · 3.26 KB
/
view_packages_T_pradi.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
<?php
include_once 'P_header2.php';
?>
<div>
<script>
function checkUsername(username) {
if (username) {
window.location.href = "P_reserve.php";
} else {
window.location.href = "s_loginForm.html";
}
}
</script>
<?php
$select=mysqli_query($conn,"SELECT*FROM hotel_package");
?><br><br>
<div class="form-group">
<input type="text" id="myInput" onkeyup="searchTable()" placeholder="Search.." class="form-control">
</div>
<section class="View_Data_T2" >
<div class="content_package1">
<p>
<table id="mySection" >
<?php
while($row=mysqli_fetch_assoc($select)){
?>
<tr>
<td>
<div class="image12">
<img src="<?php echo $row['Image'];?>" height=100 alt="Package_image" class="image1">
</div>
</td>
<td>
<?php echo $row['Package_Name'];?><br>
</td>
<td>
<?php
$Hotel = $row['Hotel_ID'];
$hotelSelect = mysqli_query($conn, "SELECT `Hotel_Name` FROM `hotel` WHERE `Hotel_ID`='$Hotel'");
$row1 = mysqli_fetch_assoc($hotelSelect);
$hotelName = $row1['Hotel_Name'];
echo $hotelName;
?>
</td>
<td>
<?php echo $row['Package_Price'];?>
</td>
<td>
<?php echo $row['Package_Type'];?>
</td>
<td>
<form action="View_fullpackages_T.php" method="POST">
<input type="hidden" name="view" value="<?php echo $row['Package_ID']; ?>">
<button type="submit" class="view_T">VIEW</button>
</form>
</td>
<td>
<button type="submit" class="view_T"onclick="checkUsername('<?php echo $Username; ?>')" >RESERVE</button>
</td>
</tr>
<?php };?>
</table>
</p>
</div>
</section>
</div>
<?php
include_once 'P_footer.php';
?>