Airline Documentation Final
Airline Documentation Final
This initiative aims to construct an airline booking system based on the web. There are
few technical problems with the existing system of airline reservations, from the fact that
passengers are not permitted to cancel their ticket, to the fact that passengers cannot view
the pricing charts. This requires that a new system be developed to rectify this issue. If
the problems occur and the pricing chat does not occur in the older system, the new
system will enable the passenger to cancel his booking. This system enables air travelers
to search for flights between the two cities of travel: the 'City of departure' and the 'City
of destination' for a given date of departure and destination. The aim is to establish a
web-based system to ensure that online flight reservations can be made, that passengers
have access to online proposals and complaints, and that online news publishing is
available to customers by flight providers. The methodology used for this project is the
life cycle of software development (SDLC). It is built with PHP, MYSQL, and
JavaScript. This current technology will enhance the flexibility and reliability of
passenger airline relations. This work has been effective in designing an airline booking
system on the Internet which solves the passengers' unavailability to cancel their ticket
options and offers easy flight information access.
INTRODUCTION
One of the earliest changes to improve efficiency was the airline reservation system. The
airline reservations system eventually became the CRS and then the global distribution
system (GDS). As a means of tracing flight schedule, availability and costs, the airline
industry established the first GDS in the 1960s. Although accused of "dinosaurs," GDSs
were among the first e-commerce firms in the world to facilitate B-2-B electronic trade in
Over the previous four years, the World Wide Web has grown quite important, and most
airlines currently arrange to book their trips online. The Internet has become an important
resource for consumers who wish to make online reservations without having to meet
travel agents.
The SDLC is a process that delivers high-quality software with the lowest costs in the
quickest period possible. SDLC has a precise plan for how a software system is
deployment.
SDLC works by reducing software development costs while at the same time increasing
quality and reducing production time. By implementing a plan to remove the typical
problems for development projects, SDLC meets these apparently different goals This
plan begins with an assessment of existing deficiency systems. It then sets out the revised
system requirements. Then the software can be designed, designed, constructed, tested
and used. By predicting expensive errors, such as the absence of proposals from the end
user. Big Bang is an example of SDLC. This strategy provides greater development
Objective
Details on flight schedules and fares, passenger reservations, as well as ticket documents
are provided via the Airline Reservation System. An inventory of airlines includes all
flights with seats. The airline services' inventory is usually separated into three class
categories as well as pricing and booking restrictions for each category. Inventory data is
imported and kept across standardized interfaces via a schedule distribution system. One
Controls the inventory by opening and shutting various booking classes, how many seats
for the different booking classes are available. The prices for each seat sold shall be
• All functions are carried out using a mouse click to construct an airline management
system
• Develop a system with appropriate data management, integrity and redundancy
minimization.
It aims to develop the new and better alternative system to assist the organization in
producing operational reports where necessary, that is to say reporting operational details
which reflect airline operations on a daily basis, safeguard the system database's data and
information, and record flights and transactions in an accurate manner.
Details on flight schedules and fares, passenger reservations, as well as ticket documents
are provided via the Airline Reservation System. The airline service inventory is usually
separated into three classes, e.g. first class, business class or economical class, with
unlimited bookings in each category along with rates and reservation criteria. Controls
the inventory by opening and shutting various booking classes, how many seats for the
different booking classes are available. The prices for each seat sold shall be established
together with the prices and booking conditions specified in the Fare Quote System.
PROBLEM DEFINITION
The globe has become a global village in the 21st century, with everything available with
one mouse click. The aviation industry is one of the fastest available modes of transport,
both domestically and internationally. It's a difficult task to maintain a large system. The
Manual system: the system is more susceptible to errors and has various unstructured
problems.
Technical system: If we do not upgrade our system, the latest technology will result in
huge financial losses for our companies. The technical system (we have designed)
includes the current trend equipment such as computer printers, faxes etc. The systems
utilizing this technology are incredibly fast, accurate, easy to use and trustworthy.
SYSTEM ARCHITECTURE
The application will follow the architecture of three levels. The typical client/server
model, but from the web server, is used in the three-tier architecture application. The
customer merely shows the GUI and data but does not contribute to the results of this
process.
Customer/Tier presentation:
This level contains all the HTML contents or forms on the client's browser. It is the form
that gives the end-user interface. The programmer utilizes the tier to either retrieve or
retrieve data.
Layer of business logic
The real processing of the data and the logic underlying the application implementation
will be present in the business logic level. This level can include a class that can write the
features and can also act as a mediator between the display level and the data level.
Tier of Data:
Data Tier includes methods and classes for data transmission and storage on the storage
layer. Queries or saved procedures are used for accessing or operating the database data
from the database. The data passed by the presentation level are stored.
Unified Language Modeling: UML stands for Unified Language Modeling. It is a method
of third generation for the definition, visualization and documentation of the object-
oriented system objects being developed. Object model is the method through which the
actual items in the program represent the logical objects in the real world (Problem space)
(logical or a mini world). This graphic depiction is a simple way of understanding of
objects, their relations and their structures. After analysis, this is one step in developing
any product.
There are a variety of models in the Unified Modeling Language.
1. Use diagrams for cases
2. Diagrams of class
3. Diagrams of sequence
Theoretical Background
The Technologies used in this work are listed below
PHP: PHP is a language for creating webpages that are dynamic, interactive and user
friendly. It can be incorporated in the HTML (hypertext mark-up language).
A few factors that direct us to develop a new system are given below -:
1. 1) Faster System
2) Accuracy
3) Reliability
4) Informative
5) Reservations.
We have a variety of language options. From these alternatives we can select the right
4. ANALYSIS
Verification
SYSTEM Log In ENTER
User Name VERIFIY Success
ADMINSTRATOR USERNAM USERNAME Airline
E Password
PASSWORD Reservatio
PASSWOR Verification n
D System
Verification
Fail
EXIT
FROM
SYSTEM
Fig 4 : First level of DATA flow Diagram
Unlike simple programs which can be built isolated, and no systematic strategy may be
Because programming and software engineering are very different. It provides models
process, the time and effort required to generate the end result should be determined in
advance. I have to follow some models as guidelines for the development of successful
software.
Waterfall model or Classic Life Cycle is the model we have utilized. The existing system
is initially observed in this model. The clients' requirements are then taken into account,
then planned, modelled, built and finally deployed.
Fig 9 . Waterfall Model
Gantt chart
The Gantt chart is a time-based visual representation of the task. They contain vital
information like as who is in charge of what, as well as the project's duration and overlap.
The system's Gantt chart is depicted in the diagram below:
observations and procedural handbooks and so on. The system flowcharts, data flow
diagrams, structured English, decision tables and the like are necessary for organizing
The data flow diagrams and different processing logic techniques illustrate how, when
and where data is being utilized or altered in the information system, but the definition,
structure and relationships within data are not displayed by those techniques.
It's not a physical implementation but a manner of concentrating on functions. This is like
the blueprint of the architect for system design. This is the same. In contrast to analysis,
The design of the system is incredibly imaginative. Also known as data modelling this
system design process. The most popular formatted E-R notation illustrates the properties
and data structure, regardless of the way data can be stored in computer memory.
External Interfaces
The different interfaces we would come across while developing the Airline
Reservation System are:
User Interface
Hardware Interface
Software Interface
User Interface
Fig 11: User Interface
Software Interface
Any operating system can execute this application. It is run under Windows 7 OS in beta
version. The program requires a database to record flight details, user details and
reservation details etc. All coding in PHP is performed through CSS and HTML. For web
hosting on local port, Xampp Control Panel is utilized.
Registration Module
First, we invite passengers to provide their details in the registration module. Upon
registration with us the passenger may sign up for his/her own account and can examine
the specifics of the flight including timings, prices, seat availability. Passers can reserve
any number of tickets once registered with us.
Administration module
For the sake of administrators, the administrative module is offered to maintain the site
and to update the contents on a regular basis.
This module is designed for passengers who view this panel when a user logs into his or
her account. This module included the most important operations
See all airline schedules, timetables, pricing details and available seats.
Book for tickets. Book for tickets.
Ticket view and cancelation.
Feedback sending
Implementation
Coding
Index.php
Logout.php
Fig 17: Logout Session
In above figure, it is for destroy the session of user and admin through logout option in
top of the web page.
Screenshots of user flight booking page
Database Screenshots
All the fundamental features needed for airline bookings to be booked/canceled are
provided for the proposed system. The system will also be improved in the future. Some
of the factors envisioned in a future version 2.0 are as follows:
• Reservation and cancelation SMS confirmations
• The new class known as Standees is available, which enables short distance customers
to cover the entirety of the flight.
• Multi-stop flight reservation introduction
This system can be changed as an online system.
• The multi-user interface is added to this system.
The Aviaries will replace the airline booking system of open skies while planning for
further growth.
Recommendation
We advocate a parallel change for this piece of research, a parallel change in a
circumstance in which the old systems and new systems work simultaneously for a
specific time period. This tends to be the most common techniques since it poses the
lowest risk because the whole system can be returned to its previous position if
something goes wrong at any time.
Appendix 1
1. Index page
<?php
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
?>
<div class="row">
<div class="col-lg-4">
<div class="well bs-component">
<form class="form-horizontal" action="" method="GET">
<legend>Search Flights</legend>
<div class="form-group">
<div class="col-lg-10">
<div class="radio">
<label>
<input type="radio" name="path" value="oneway"
onclick="setReadOnly(this)">
One Way
</label>
<label>
<input type="radio" name="path" value="return" checked
onclick="setReadOnly(this)">
Return
</label>
</div>
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">From</label>
<input class="form-control" name="from_city" id="from_city" value="<?php
if(isset($_GET['from_city'])) { echo htmlentities ($_GET['from_city']); } else echo '';?>"
required type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">To</label>
<input class="form-control" name="to_city" id="to_city" value="<?php
if(isset($_GET['to_city'])) { echo htmlentities ($_GET['to_city']); } else echo '';?>"
required type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Departure Date</label>
<input class="form-control" name="departure_date" id="departure_date"
value="<?php if(isset($_GET['departure_date'])) { echo htmlentities
($_GET['departure_date']); } else echo '';?>" required type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Arrival Date</label>
<input class="form-control" name="return_date" id="return_date" value="<?
php if(isset($_GET['return_date'])) { echo htmlentities ($_GET['return_date']); } else
echo '';?>" required type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label for="select" class="control-label">Number of Adults</label>
<select class="form-control" name="count_a" id="select">
<option value="1">1</option>
</select>
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label for="select" class="control-label">Number of Children</label>
<select class="form-control" name="count_c" id="select">
<option value="0">0</option>
<option value="1">1</option>
</select>
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label for="select" class="control-label">Class</label>
<select class="form-control" name="class" id="select">
<option name="economy" value="Economy">Economy</option>
<option name="business" value="Business">Business</option>
</select>
<br>
</div>
</div>
<div class="form-group">
<center><button type="submit" id="submit" value="submit" name="submit"
class="btn btn-primary">Submit</button></center>
</div>
</form>
</div>
</div>
<div class="col-lg-8">
<div class="well bs-component">
<form class="form-horizontal" action="book.php" method="GET">
<?php
if(isset($_GET['path'])===true
&& isset($_GET['from_city'])===true && isset($_GET['to_city'])===true
&& isset($_GET['departure_date'])===true
&& isset($_GET['count_a'])===true && isset($_GET['count_c'])===true &&
isset($_GET['class'])===true) {
$from = $_GET['from_city'];
$to = $_GET['to_city'];
$departdate = $_GET['departure_date'];
$class = $_GET['class'];
$path = $_GET['path'];
$counta = $_GET['count_a'];
$countc = $_GET['count_c'];
if($path==='oneway') {
echo '<legend>Flights from '.$from.' to '.$to.'</legend>';
$query = "SELECT * FROM `flight_search` WHERE `from_city`= '$from'
AND `to_city` = '$to' AND `departure_date` = '$departdate'";
$result = mysql_query($query);
if($result) {
if(mysql_num_rows($result) > 0) {
while($row = mysql_fetch_assoc($result)) {
?>
<table class="table">
<thead>
<tr>
<th>Flight No</th>
<th>Departure Time</th>
<th>Arrival Time</th>
<th>Seats Left</th>
<th>Price</th>
</tr>
</thead>
<tbody>
<tr>
<?php if($class==='Economy') { ?>
<td><input type="radio" name="chose_to" value="<?php echo $row['fno']; ?
>"/><?php echo $row['fno']; ?></td>
<td><?php echo $row['departure_time']; ?></td>
<td><?php echo $row['arrival_time']; ?></td>
<td><?php echo $row['e_seats_left']; ?></td>
<td><?php echo $row['e_price']; ?></td>
<?php } else if($class==='Business') { ?>
<td><input type="radio" name="chose_to" value="<?php echo $row['fno']; ?
>"/><?php echo $row['fno']; ?></td>
<td><?php echo $row['departure_time']; ?></td>
<td><?php echo $row['arrival_time']; ?></td>
<td><?php echo $row['b_seats_left']; ?></td>
<td><?php echo $row['b_price']; ?></td>
<?php } else { 'Not enough seats left, please search again!'; }
}?>
</tr>
</tbody>
</table>
<input type="hidden" name="count_a" value="<?php echo $counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo $countc; ?>"/>
<center><button type="submit" id="class" name="class" value="<?php echo
$class; ?>" class="btn btn-primary">Choose Flights</button></center>
<?php
} else { echo 'No flights found';}
}
else { die(mysql_error()); }
}
else if($path==='return') {
echo '<legend>Flights from '.$from.' to '.$to.'</legend>';
$query1 = "SELECT * FROM `flight_search` WHERE `from_city`= '$from'
AND `to_city` = '$to' AND `departure_date` = '$departdate'";
$result1 = mysql_query($query1);
if($result1) {
if(mysql_num_rows($result1) > 0) {
while($row1 = mysql_fetch_assoc($result1)) {
?>
<table class="table">
<thead>
<tr>
<th>Flight No</th>
<th>Departure Time</th>
<th>Arrival Time</th>
<th>Seats Left</th>
<th>Price</th>
</tr>
</thead>
<tbody>
<tr>
<?php if($class==='Economy') { ?>
<?php include
$_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php'; ?>
2. Login Page
<?php
$title = 'Swift Airlines | Login';
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
f_logged_in_redirect();
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
?>
<?php include
$_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php'; ?>
3. Booking page
<?php
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
?>
<legend>My Bookings</legend>
<?php
$uid=$f_data['f_id']; //Assigns logged in id to a variable
$query="SELECT * FROM `passenger_details` WHERE `p_fid` = '$uid'"; //Sorts
by date time
$result=mysql_query($query);
if($result) {
while($row=mysql_fetch_assoc($result))
{
if($uid===$row['p_fid']) //Checks if the logged in id matches with id in DB
{
$pnr = $row['p_pnr'];
$fno = $row['p_fno'];
echo '<form action="cancel.php" method="POST">';
echo 'Flight No: '.
$row['p_fno'].' ';
echo 'From: '.$row['p_from'].' ';
echo 'To: '.$row['p_to'].' ';
echo 'Class: '.$row['p_class'].' ';
echo 'PNR Number: '.
$row['p_pnr'].' '.'<br/>';
echo 'Departure Date: '.
$row['p_dedate'].' ';
echo 'Departure Time: '.
$row['p_detime'].' ';
echo 'Arrival Date: '.
$row['p_ardate'].' ';
echo 'Arrival Time: '.
$row['p_artime'].' '.'<br/>';
echo 'Passenger Name: '.
$row['p_name'].' '.'<br>';
echo 'Passenger Age: '.
$row['p_age'].' '.'<br>';
echo 'Passenger Sex: '.
$row['p_sex'].' '.'<br>';
echo 'Passenger Type: '.
$row['p_passtype'].' '.'<br><br>';
echo "<input type='hidden' value='$pnr' id='p_pnr' name='p_pnr' />";
echo "<input type='hidden' value='$fno' id='p_fno' name='p_fno' />";
if($row['p_status']==='Booked') {
echo '<button type="submit" value="cancel" name="cancel" class="btn btn-
primary">Cancel Bookings</button>';
echo '<br/><hr>';
echo '</form>';
} else {
echo '<br/><hr>';
echo '</form>';
}
}
}
}
?>
<?php include
$_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php'; ?>
4. Cart Page
<?php
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
?>
<div class="row">
<div class="col-lg-4">
</div>
<div class="col-lg-4">
<div class="well bs-component">
<?php
if(f_logged_in()===true) {
$puname = $_GET['puname'];
$puadd = $_GET['puadd'];
$puphno = $_GET['puphno'];
$pumail = $_GET['pumail'];
if(isset($_GET['chose_to'])===true) {
$to = $_GET['chose_to'];
$class = $_GET['class'];
$counta = $_GET['count_a'];
$countc = $_GET['count_c'];
if(isset($_GET['chose_fro'])===true)
{
$fro = $_GET['chose_fro'];
if($class==='Economy') {
$eat1 =
$_GET['eat1'];
$eat2 =
$_GET['eat2'];
$ect1 =
$_GET['ect1'];
$ect2 =
$_GET['ect2'];
$etax1 = $etax2 =
500;
$etot1 = $eat1 + $ect1
+ $etax1;
$etot2 = $eat2 + $ect2
+ $etax2;
$etotr = $etot1 +
$etot2;
if($countc==='0') {
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='1')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='2')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
$cname2 =
$_GET['cname2'];
$csex2 =
$_GET['csex2'];
$cage2 =
$_GET['cage2'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
}
else if($class==='Business') {
$bat1 =
$_GET['bat1'];
$bat2 =
$_GET['bat2'];
$bct1 =
$_GET['bct1'];
$bct2 =
$_GET['bct2'];
$btax1 = $btax2 =
1500;
$btot1 = $bat1 +
$bct1 + $btax1;
$btot2 = $bat2 +
$bct2 + $btax2;
$btotr = $btot1 +
$btot2;
if($countc==='0') {
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='1')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='2')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
$cname2 =
$_GET['cname2'];
$csex2 =
$_GET['csex2'];
$cage2 =
$_GET['cage2'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
}
}
else {
if($class==='Economy') {
$eat1 =
$_GET['eat1'];
$ect1 =
$_GET['ect1'];
$etax1 = 500;
$etot1 = $eat1 + $ect1
+ $etax1;
if($countc==='0') {
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='1')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='2')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
$cname2 =
$_GET['cname2'];
$csex2 =
$_GET['csex2'];
$cage2 =
$_GET['cage2'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
}
else if($class==='Business') {
$bat1 =
$_GET['bat1'];
$bct1 =
$_GET['bct1'];
$btax1 = 1500;
$btot1 = $bat1 +
$bct1 + $btax1;
if($countc==='0') {
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='1')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
else if($countc==='2')
{
$cname1 =
$_GET['cname1'];
$csex1 =
$_GET['csex1'];
$cage1 =
$_GET['cage1'];
$cname2 =
$_GET['cname2'];
$csex2 =
$_GET['csex2'];
$cage2 =
$_GET['cage2'];
if($counta==='1') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
}
else
if($counta==='2') {
$aname1 = $_GET['aname1'];
$aage1
= $_GET['aage1'];
$asex1
= $_GET['asex1'];
$aname2 = $_GET['aname2'];
$aage2
= $_GET['aage2'];
$asex2
= $_GET['asex2'];
}
}
}
}
}
}
?>
<legend>Credit/Debit Card Details</legend>
<form class="form-horizontal" action="confirm.php"
method="POST">
<div class="form-group">
<div class="col-lg-12">
<input type="text" required class="form-control" maxlength="32"
name="carduser" id="carduser" placeholder="Card Holder Name">
</div>
</div>
<div class="form-group">
<div class="col-lg-8">
<input type="text" required maxlength="16" class="form-control"
name="cardnum" id="cardnum" placeholder="Card Number">
</div>
<div class="col-lg-4">
<input type="password" required maxlength="3" class="form-
control" name="cvvnum" id="cvvnum" placeholder="CVV">
</div>
</div>
<center>
<?php
if(isset($_GET['chose_to'])===true) {
if(isset($_GET['chose_fro'])===true) {
if($class==='Economy' && $counta==='1'
&& $countc==='0') {
?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="ect2" value="<?php echo
$ect2; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="eat2" value="<?php echo
$eat2; ?>"/>
<input type="hidden" name="etotr" value="<?php echo
$etotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<?php }
else if($class==='Business' && $counta==='1' && $countc==='0')
{ ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bct2" value="<?php echo
$bct2; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="bat2" value="<?php echo
$bat2; ?>"/>
<input type="hidden" name="btotr" value="<?php echo
$btotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<?php }
else if($class==='Economy' && $counta==='2' && $countc==='0')
{ ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="ect2" value="<?php echo
$ect2; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="eat2" value="<?php echo
$eat2; ?>"/>
<input type="hidden" name="etotr" value="<?php echo
$etotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1"
value="<?php echo $aage1; ?>"/>
<input type="hidden" name="asex1"
value="<?php echo $asex1; ?>"/>
<input type="hidden" name="aname2"
value="<?php echo $aname2; ?>"/>
<input type="hidden" name="aage2"
value="<?php echo $aage2; ?>"/>
<input type="hidden" name="asex2"
value="<?php echo $asex2; ?>"/>
<?php }
else if($class==='Business' && $counta==='2' && $countc==='0')
{ ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bct2" value="<?php echo
$bct2; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="bat2" value="<?php echo
$bat2; ?>"/>
<input type="hidden" name="btotr" value="<?php echo
$btotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1"
value="<?php echo $aage1; ?>"/>
<input type="hidden" name="asex1"
value="<?php echo $asex1; ?>"/>
<input type="hidden" name="aname2"
value="<?php echo $aname2; ?>"/>
<input type="hidden" name="aage2"
value="<?php echo $aage2; ?>"/>
<input type="hidden" name="asex2"
value="<?php echo $asex2; ?>"/>
<?php }
else if($class==='Economy' && $counta==='1' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="ect2" value="<?php echo
$ect2; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="eat2" value="<?php echo
$eat2; ?>"/>
<input type="hidden" name="etotr" value="<?php echo
$etotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Business' && $counta==='1' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bct2" value="<?php echo
$bct2; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="bat2" value="<?php echo
$bat2; ?>"/>
<input type="hidden" name="btotr" value="<?php echo
$btotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Economy' && $counta==='1' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="ect2" value="<?php echo
$ect2; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="eat2" value="<?php echo
$eat2; ?>"/>
<input type="hidden" name="etotr" value="<?php echo
$etotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
else if($class==='Business' && $counta==='1' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bct2" value="<?php echo
$bct2; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="bat2" value="<?php echo
$bat2; ?>"/>
<input type="hidden" name="btotr" value="<?php echo
$btotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
else if($class==='Economy' && $counta==='2' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="ect2" value="<?php echo
$ect2; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="eat2" value="<?php echo
$eat2; ?>"/>
<input type="hidden" name="etotr" value="<?php echo
$etotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2"
value="<?php echo $aage2; ?>"/>
<input type="hidden" name="asex2"
value="<?php echo $asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Business' && $counta==='2' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bct2" value="<?php echo
$bct2; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="bat2" value="<?php echo
$bat2; ?>"/>
<input type="hidden" name="btotr" value="<?php echo
$btotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2"
value="<?php echo $aage2; ?>"/>
<input type="hidden" name="asex2"
value="<?php echo $asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Economy' && $counta==='2' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="ect2" value="<?php echo
$ect2; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="eat2" value="<?php echo
$eat2; ?>"/>
<input type="hidden" name="etotr" value="<?php echo
$etotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2"
value="<?php echo $aage2; ?>"/>
<input type="hidden" name="asex2"
value="<?php echo $asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
else if($class==='Business' && $counta==='2' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="chose_fro" value="<?php
echo $fro; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bct2" value="<?php echo
$bct2; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="bat2" value="<?php echo
$bat2; ?>"/>
<input type="hidden" name="btotr" value="<?php echo
$btotr; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2"
value="<?php echo $aage2; ?>"/>
<input type="hidden" name="asex2"
value="<?php echo $asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
}
else {
if($class==='Economy' && $counta==='1' &&
$countc==='0') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="etot1" value="<?php echo
$etot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<?php }
else if($class==='Business' && $counta==='1' &&
$countc==='0') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="btot1" value="<?php echo
$btot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<?php }
else if($class==='Economy' && $counta==='1' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="etot1" value="<?php echo
$etot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Business' && $counta==='1' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="btot1" value="<?php echo
$btot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Economy' && $counta==='1' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="etot1" value="<?php echo
$etot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
else if($class==='Business' && $counta==='1' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="btot1" value="<?php echo
$btot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
else if($class==='Economy' && $counta==='2' &&
$countc==='0') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="etot1" value="<?php echo
$etot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2" value="<?php echo
$aage2; ?>"/>
<input type="hidden" name="asex2" value="<?php echo
$asex2; ?>"/>
<?php }
else if($class==='Business' && $counta==='2' &&
$countc==='0') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="btot1" value="<?php echo
$btot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2" value="<?php echo
$aage2; ?>"/>
<input type="hidden" name="asex2" value="<?php echo
$asex2; ?>"/>
<?php }
else if($class==='Economy' && $counta==='2' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="etot1" value="<?php echo
$etot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2" value="<?php echo
$aage2; ?>"/>
<input type="hidden" name="asex2" value="<?php echo
$asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Business' && $counta==='2' &&
$countc==='1') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="btot1" value="<?php echo
$btot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2" value="<?php echo
$aage2; ?>"/>
<input type="hidden" name="asex2" value="<?php echo
$asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<?php }
else if($class==='Economy' && $counta==='2' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="ect1" value="<?php echo
$ect1; ?>"/>
<input type="hidden" name="eat1" value="<?php echo
$eat1; ?>"/>
<input type="hidden" name="etot1" value="<?php echo
$etot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2" value="<?php echo
$aage2; ?>"/>
<input type="hidden" name="asex2" value="<?php echo
$asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
else if($class==='Business' && $counta==='2' &&
$countc==='2') { ?>
<input type="hidden" name="count_a" value="<?php echo
$counta; ?>"/>
<input type="hidden" name="count_c" value="<?php echo
$countc; ?>"/>
<input type="hidden" name="chose_to" value="<?php
echo $to; ?>"/>
<input type="hidden" name="class" value="<?php echo
$class; ?>"/>
<input type="hidden" name="bct1" value="<?php echo
$bct1; ?>"/>
<input type="hidden" name="bat1" value="<?php echo
$bat1; ?>"/>
<input type="hidden" name="btot1" value="<?php echo
$btot1; ?>"/>
<input type="hidden" name="aname1" value="<?php echo
$aname1; ?>"/>
<input type="hidden" name="aage1" value="<?php echo
$aage1; ?>"/>
<input type="hidden" name="asex1" value="<?php echo
$asex1; ?>"/>
<input type="hidden" name="aname2" value="<?php echo
$aname2; ?>"/>
<input type="hidden" name="aage2" value="<?php echo
$aage2; ?>"/>
<input type="hidden" name="asex2" value="<?php echo
$asex2; ?>"/>
<input type="hidden" name="cname1" value="<?php echo
$cname1; ?>"/>
<input type="hidden" name="cage1" value="<?php echo
$cage1; ?>"/>
<input type="hidden" name="csex1" value="<?php echo
$csex1; ?>"/>
<input type="hidden" name="cname2" value="<?php echo
$cname2; ?>"/>
<input type="hidden" name="cage2" value="<?php echo
$cage2; ?>"/>
<input type="hidden" name="csex2" value="<?php echo
$csex2; ?>"/>
<?php }
}
}
?>
<input type="hidden" name="puname" value="<?php echo $puname; ?
>"/>
<input type="hidden" name="puadd" value="<?php echo $puadd; ?>"/>
<input type="hidden" name="puphno" value="<?php echo $puphno; ?
>"/>
<input type="hidden" name="pumail" value="<?php echo $pumail; ?
>"/>
<button type="submit" id="book_f" name="book_f" class="btn btn-
primary">Pay</button></center>
</form>
</div>
</div>
<div class="col-lg-4">
</div>
</div>
<?php include
$_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php'; ?>
5. Confirm Page
<?php
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
if(f_logged_in()===true) {
$uid = $f_data['f_id'];
if(isset($_POST['cardnum'])===true &&
isset($_POST['cvvnum'])===true) {
$cardnum = $_POST['cardnum'];
$cvvnum = $_POST['cvvnum'];
$puname = $_POST['puname'];
$puphno = $_POST['puphno'];
$puadd = $_POST['puadd'];
$pumail = $_POST['pumail'];
if(isset($_POST['chose_to'])===true) {
if(isset($_POST['chose_fro'])===true) {
$to = $_POST['chose_to'];
$fro = $_POST['chose_fro'];
$counta = $_POST['count_a'];
$countc = $_POST['count_c'];
$class = $_POST['class'];
if($class==='Economy' && $counta==='1' &&
$countc==='0') {
$aname1 = $_POST['aname1'];
$asex1 = $_POST['asex1'];
$aage1 = $_POST['aage1'];
$ect1 = $_POST['ect1'];
$ect2 = $_POST['ect2'];
$eat1 = $_POST['eat1'];
$eat2 = $_POST['eat2'];
$etotr = $_POST['etotr'];
$totc = $counta + $countc;
$status = 'Booked';
$q1 = "SELECT * FROM `flight_search`
WHERE `fno`='$to'";
$r1 = mysql_query($q1);
while($row1 = mysql_fetch_assoc($r1)) {
$from_city = $row1['from_city'];
$to_city = $row1['to_city'];
$depart_date =
$row1['departure_date'];
$arr_date = $row1['arrival_date'];
$depart_time =
$row1['departure_time'];
$arr_time = $row1['arrival_time'];
}
$q10 = "SELECT `c_balance` FROM
`card_details` WHERE `c_cvv`='$cvvnum' AND `c_cnum`='$cardnum'";
$r10 = mysql_query($q10);
if($r10) {
if(mysql_num_rows($r10)>0) {
while($row10 =
mysql_fetch_assoc($r10)) {
$balance =
$row10['c_balance'];
if($balance>=$etotr)
{
$deduct =
$balance - $etotr;
if(mysql_num_rows($r11)>0) {
while($row11 = mysql_fetch_assoc($r11)) {
$e_seats_left = $row11['e_seats_left'];
}
}
date_default_timezone_set('Asia/Kolkata');
$a1 =
date('H:i:s');
$e1 =
str_replace(':', '', $a1);
$a2 =
date('d-m-Y');
$e2 =
str_replace('-', '', $a2);
$pnr1
= $e1.$e2;
if(mysql_num_rows($r12)>0) {
while($row12 = mysql_fetch_assoc($r12)) {
$e_seats_left = $row12['e_seats_left'];
}
}
date_default_timezone_set('Asia/Kolkata');
$a5 =
date('H:i:s');
$e5 =
str_replace(':', '', $a5);
$a6 =
date('d-m-Y');
$e6 =
str_replace('-', '', $a6);
$pnr6
= $e5.$e6+100;
}
else {
echo
'Insufficient balance, tickets not booked';
?>
<?php include
$_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php'; ?>
6. Register Page
<?php
$title = 'Swift Airlines | User Registration';
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
f_logged_in_redirect();
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
if(empty($_POST)===false) {
$required_fields =
array('f_uname','f_password','f_password_again','f_fname','f_lname','f_mailid','f_sex','f_a
ddress','f_phone');
foreach($_POST as $key=>$value) {
if(empty($value) && in_array($key, $required_fields) === true ) {
$errors[] = 'All the fields are required!';
break 1;
}
}
}
}
?>
<div class="row">
<div class="col-lg-4">
<div class="well bs-component">
<?php
if(isset($_GET['success']) && empty($_GET['success'])) {
echo 'You have been registered to Swift Airlines
successfully! Please check your Email ID for activation link!';
}
else {
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">First Name</label>
<input class="form-control" name="f_fname" id="f_fname" required
type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Last Name</label>
<input class="form-control" name="f_lname" id="f_lname" required
type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-10">
<div class="radio">
<label>
<input type="radio" name="f_sex" value="male" required />
Male
</label>
<label>
<input type="radio" name="f_sex" value="female" required />
Female
</label>
</div>
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Username</label>
<input class="form-control" name="f_uname" id="f_uname" required
type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Password</label>
<input class="form-control" name="f_password" id="f_password" required
type="password">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Confirm Password</label>
<input class="form-control" name="f_password_again"
id="f_password_again" required type="password">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Email ID</label>
<input class="form-control" name="f_mailid" id="f_mailid" required
type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Address</label>
<input class="form-control" name="f_address" id="f_address" required
type="text">
</div>
</div>
<div class="form-group">
<div class="col-lg-12">
<label class="control-label" for="focusedInput">Phone Number</label>
<input class="form-control" name="f_phone" id="f_phone" required
type="text">
</div>
</div>
<div class="form-group">
<center><button type="submit" id="submit" value="submit" name="submit"
class="btn btn-primary">Register</button></center>
</div>
</form>
</div>
</div>
</div>
<?php
}
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php'; ?>
7. Profile Page
<?php
$title = 'Swift Airlines | Profile';
include $_SERVER["DOCUMENT_ROOT"].'/swift/core/init.php';
user_protect_page();
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/header.php';
if(isset($_GET['f_uname']) === true && empty($_GET['f_uname']) === false) {
$f_uname = $_GET['f_uname'];
if(f_exists($f_uname) === true ) {
$f_id = f_id_from_username($f_uname);
$profile_data = f_data($f_id,
'f_fname','f_lname','f_mailid','f_sex','f_regdate');
?>
<br/>
<div class="container">
<img src="http://localhost/<?php echo $profile_data['f_dp'] ?>" height="150"
width="150" />
</div>
<hr>
<?php
}
else {
echo 'Sorry, that user doesn\'t exists!';
}
}
else {
header('Location: http://localhost/swift/index.php');
exit();
}
include $_SERVER["DOCUMENT_ROOT"].'/swift/includes/overall/footer.php';
?>
Appendix 2
Datebase (SQL)
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET
@OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET
@OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET
@OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
--
-- Database: `swift`
--
-- --------------------------------------------------------
--
-- Table structure for table `booking_details`
--
--
-- Dumping data for table `booking_details`
--
-- --------------------------------------------------------
--
-- Table structure for table `card_details`
--
--
-- Dumping data for table `card_details`
--
-- --------------------------------------------------------
--
-- Table structure for table `flight_search`
--
--
-- Dumping data for table `flight_search`
--
-- --------------------------------------------------------
--
-- Table structure for table `flight_users`
--
--
-- Dumping data for table `flight_users`
--
-- --------------------------------------------------------
--
-- Table structure for table `passenger_details`
--
--
-- Dumping data for table `passenger_details`
--