-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathresult.php
138 lines (131 loc) · 5.89 KB
/
result.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
<?php require('header.php');
include "database.php";
?>
<html>
<head>
<title></title>
<style>
body{
opacity: 0;
transition: opacity 6s;
}
.fdetail_cont{ width: 100%;background: whitesmoke;text-align: center;display: block;position: relative;border:1px solid #a6a6a6;box-shadow: 2px 2px 5px 5px #b3b1b1;margin-bottom: 20px;}
.fdetail_cont .fdetail{animation-iteration-count: 1;animation: evenfade ease-in 3s;
width: 70%; height: 90px; background: white;text-align: center;display: block;position: relative;border:1px solid #a6a6a6;margin-top: 15px;margin-bottom: 15px;margin-left: 15%;box-shadow: 2px 2px 2px #9b9e9c;}.fdetail_cont .fdetail img{width: 70px; float: left; align-items: center; margin-top: 10px; border-radius: 50%;}.fdetail_cont .fdetail .aaaa .tag{ font-size: 15px; }.fdetail_cont .fdetail .aaaa{ float: left; text-align: center; font-family: sans-serif; font-size: 50px; margin-top: 20px; margin-bottom: 20px; }.fdetail_cont .fdetail .aaaa span:not(.not){ padding-left: 25px;}.fdetail_cont .fdetail .aaaa span:not(.tag){font-size: 25px;}.fdetail_cont .fdetail .aaaa .btn a{text-decoration: none; background: #18a30b; border: 1px solid #0d5906; color: white; border-radius: 10px; outline: none; padding: 5px;" }
.btn a:hover{color: red;}
</style>
</head><body style="background: white;" onload="document.body.style.opacity='1'">
<?php
if (isset($_POST['submit']))
{
$from= $_POST["from"];
$to= $_POST["to"];
$date=$_POST["date"];
$pass=$_POST["pas"];
$_SESSION['pass'] = $pass;
$_SESSION['date'] = $date;
$query=" SELECT * FROM schedule WHERE f_from='$from' && f_to='$to' ORDER BY departure ASC";
$data = mysqli_query($con,$query);
?>
<span style="margin-left: 20%; position: absolute;margin-top: 5px; font-family: sans-serif;font-size: 20px;color: red;"><?php echo "You are here : ". $from ;?></span><span style=" margin-left: 68%; position: relative;font-family: sans-serif;font-size: 20px;color: red;"><?php echo $to ;?></span>
<span style="margin-left: 60px;"><button onclick="goBack()">Back To Search...</button></h3></span>
<center><img style="position: relative; width: 50%;height: 80px;margin-top: -25px; margin-bottom: 30px; " src="gif/air_load1.gif" alt="load flight"></center>
<script>
function goBack() {
window.history.back();
}
</script>
<?php
while ($row = mysqli_fetch_array($data))
{
?>
<style type="text/css">@keyframes evenfade{
0%{opacity: 0;}
100%{opacity: 1;}
}</style>
<div class="fdetail_cont">
<div class="fdetail">
<img src="<?php echo $row['f_logo']; ?>">
<div class="aaaa">
<table style="color: #eb9b4b; font-family: sans-serif;">
<tr>
<tr style="color:#c2670c ;">
<td></td>
<td><span class="tag">From</span></td>
<td><span class="tag">To</span></td>
<td><span class="tag">Departure</span></td>
<td><span class="tag">Duration</span></td>
<td><span class="tag">Arrival</span></td>
<td><span class="tag">Price</span></td>
</tr>
<td><span style="font-size: 15px;" class="not"><?php echo $row['f_name']; ?></span></td>
<td><span><?php echo $row['f_from']; ?></span></td>
<td><span><?php echo $row['f_to']; ?></span></td>
<td><span><?php echo $row['departure']; ?></span></td>
<td><span style="color: green; font-size: 15px;">Non-Stop</span></td>
<td><span><?php echo $row['arrival']; ?></span></td>
<td><span style="color: #8c3f08;"><?php echo $row['price']; ?></span></td>
<td><span class="btn"><a href="conf_book.php<?php echo '?flight_id='.$row['f_id']; ?>&&<?php echo '?passengr='.$pass; ?>">BOOK</a></span></td>
</tr>
</table>
</div><br clear="all">
</div>
</div>
<?php
}
}else{
$to= $_GET["flight"];
$pass=1;
$_SESSION['pass'] = $pass;
$query=" SELECT * FROM schedule WHERE f_to='$to' ORDER BY departure ASC";
$data = mysqli_query($con,$query);
?>
<span style=" margin-left: 68%; position: relative;font-family: sans-serif;font-size: 20px;color: red;"><?php echo $to ;?></span>
<span style="margin-left: 60px;"><button onclick="goBack()">Back To Search...</button></h3></span>
<center><img style="position: relative; width: 50%;height: 80px;margin-top: -25px; margin-bottom: 30px; " src="gif/air_load1.gif" alt="load flight"></center>
<script>
function goBack() {
window.history.back();
}
</script>
<?php
while ($row = mysqli_fetch_array($data))
{
?>
<style type="text/css">@keyframes evenfade{
0%{opacity: 0;}
100%{opacity: 1;}
}</style>
<div class="fdetail_cont">
<div class="fdetail">
<img src="<?php echo $row['f_logo']; ?>">
<div class="aaaa">
<table style="color: #eb9b4b; font-family: sans-serif;">
<tr>
<tr style="color:#c2670c ;">
<td></td>
<td><span class="tag">From</span></td>
<td><span class="tag">To</span></td>
<td><span class="tag">Departure</span></td>
<td><span class="tag">Duration</span></td>
<td><span class="tag">Arrival</span></td>
<td><span class="tag">Price</span></td>
</tr>
<td><span style="font-size: 15px;" class="not"><?php echo $row['f_name']; ?></span></td>
<td><span><?php echo $row['f_from']; ?></span></td>
<td><span><?php echo $row['f_to']; ?></span></td>
<td><span><?php echo $row['departure']; ?></span></td>
<td><span style="color: green; font-size: 15px;">Non-Stop</span></td>
<td><span><?php echo $row['arrival']; ?></span></td>
<td><span style="color: #8c3f08;"><?php echo $row['price']; ?></span></td>
<td><span class="btn"><a href="conf_book.php<?php echo '?flight_id='.$row['f_id']; ?>">BOOK</a></span></td>
</tr>
</table>
</div><br clear="all">
</div>
</div>
<?php
}
}
include('footer.php');
?>