Commit 1c2844c0 by ruzalo

Whole project added

parents
<?php
include('session_admin.php');
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>payment</title>
<style>
* {
box-sizing: border-box;
}
.header {
border: 1px solid green;
padding: 15px;
}
.row::after {
content: "";
clear: both;
display: table;
}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover {
background-color: #111;
}
[class*="col-"] {
float: left;
padding: 15px;
border: 3px solid blue;
}
/* This is allocating layout spaces for how the website is going to be allocated the spaces for different contencts. */
.col-1 {width: 8.33%;}
.col-2 {width: 16.66%;}
.col-3 {width: 25%;}
.col-4 {width: 33.33%;}
.col-5 {width: 41.66%;}
.col-6 {width: 50%;}
.col-7 {width: 58.33%;}
.col-8 {width: 66.66%;}
.col-9 {width: 75%;}
.col-10 {width: 83.33%;}
.col-11 {width: 91.66%;}
.col-12 {width: 100%;}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover:not(.active) {
background-color: #111;
}
.active {
background-color: #4CAF50;
}
@import url(https://fonts.googleapis.com/css?family=Roboto:400,300,600,400italic);
* {
margin: 0;
padding: 0;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-font-smoothing: antialiased;
-o-font-smoothing: antialiased;
font-smoothing: antialiased;
text-rendering: optimizeLegibility;
}
body {
font-family: "Roboto", Helvetica, Arial, sans-serif;
font-weight: 100;
font-size: 15px;
line-height: 30px;
color: #777;
background: #ffffff;
}
.container {
max-width: 400px;
width: 100%;
margin: 0 auto;
position: relative;
}
#contact input[type="Airline"],
#contact input[type="Flight_Number"],
#contact input[type="Departure"],
#contact input[type="Arrival"],
#contact input[type="Time"],
#contact input[type="Morning_AfterNoon_Night"],
#contact input[type="Price"],
#contact button[type="submit"],
#contact button[type="First_Name"],
#contact button[type="Last_Name"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#contact {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#contact h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#contact h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#contact input[type="Airline"],
#contact input[type="Flight_Number"],
#contact input[type="Departure"],
#contact input[type="Arrival"],
#contact input[type="Time"],
#contact input[type="Morning_AfterNoon_Night"],
#contact input[type="Price"],
#contact input[type="First_Name"],
#contact input[type="Last_Name"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#contact input[type="Airline"]:hover,
#contact input[type="Flight_Number"]:hover,
#contact input[type="Departure"]:hover,
#contact input[type="Arrival"]:hover,
#contact input[type="Time"]:hover,
#contact input[type="Morning_AfterNoon_Night"]:hover,
#contact input[type="Price"]:hover,
#contact input[type="First_Name"]:hover,
#contact input[type="Last_Name"]:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#contact textarea {
height: 100px;
max-width: 100%;
resize: none;
}
#contact button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#contact button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#contact button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#contact input:focus,
#contact textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
::-webkit-input-placeholder {
color: #888;
}
:-moz-placeholder {
color: #888;
}
::-moz-placeholder {
color: #888;
}
:-ms-input-placeholder {
color: #888;
}
</style>
</head>
<body>
<?php
$First_Name = $Last_Name = $Flight_Number = "";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$First_Name = test_input($_POST["First_Name"]);
$Last_Name = test_input($_POST["Last_Name"]);
$Flight_Number = test_input($_POST["Flight_Number"]);
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
<div class="row">
<div class="container">
<fieldset>
<form id="contact" method="post" action="<?php $PHP_SELF?>">
<Legend><h1>Please enter customer's information</h1></Legend>
<Ledgend>First Name:</legend>
<input placeholder="First Name" type="First_Name" name="First_Name" tabindex="1" required autofocus/>
<br>
<Ledgend>Last Name:</legend>
<input placeholder="Last Name" type="Last_Name" name="Last_Name" tabindex="1" required autofocus/>
<br>
<Ledgend>Fligh Number:</legend>
<input placeholder="Flight Number" type="Flight_Number" name="Flight_Number" tabindex="2" required/>
<br>
<!-- <Ledgend>Arrival:</legend>
<input placeholder="Arrival" type="Arrival" name="Arrival" tabindex="2" required style="text-transform:uppercase" />
<br>
<Ledgend>Departure Time:</legend>
<input placeholder="Departure Time" type="Time" name="Departure_Time" tabindex="2" required/>
<br>
<Ledgend>Arrival Time:</legend>
<input placeholder="Arrival Time" type="Time" name="Arrival_Time" tabindex="2" required/>
<br>
<Ledgend>Flight Time:</legend>
<input placeholder="Flight Time" type="Time" name="Flight_Time" tabindex="2" required/>
<br>
<Ledgend>Morning, Afternoon or Night:</legend>
<input placeholder="Morning, Afternoon or Night" type="Morning_AfterNoon_Night" name="Morning_AfterNoon_Night" tabindex="1" required autofocus/>
<br>
<Ledgend>Price:</legend>
<input placeholder="Price" type="Price" name="Price" tabindex="1" required autofocus/>
<br> -->
<input type="submit" name="submit" value="Submit" />
</form>
<?php
#echo "Insert new user";
// connect to the database
$con = mysqli_connect(localhost,root, root, cs, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$data = mysqli_query($con, "SELECT Passenger_Id FROM Passenger_Profile WHERE First_Name = '$First_Name' AND Last_Name = '$Last_Name' AND Flight_Number = '$Flight_Number'");
//And display the results
while($row = mysqli_fetch_array( $data ))
{
echo "$row[0]". " ";
echo "<br>";
;
}
//This counts the number or results. If there aren't any, it gives the user a "no match" message
$anymatches=mysqli_num_rows($data);
if ($anymatches == 0)
{
echo "Sorry, but we can not find an entry to match your query<br><br>";
}
//And reminds the user what they searched for
// echo "<b>Searched For:</b> " . "$find";
// }
//break;
//
// if (isset($_GET['Passenger_Id#
// '])) {
//
// $Passenger_Id = $_GET['Passenger_Id'];
// echo $Passenger_Id;
// }
echo "Your input:::::::::<br>";
echo "".$First_Name. "<br>";
echo "".$Last_Name. "<br>";
echo "".$Flight_Number. "<br>";
//sql to delete a record
$data = mysqli_query($con, "DELETE FROM Ticket_Info WHERE Passenger_fk = $row[0]");
if (mysqli_query($con, $data)) {
echo "Record deleted successfully";
} else {
echo "Error deleting record: " . mysqli_error($con);
}
// mysqli_query($con, "DELETE FROM Ticket_Info WHERE Passenger_fk = $row[0]");
// printf("Affected rows (DELETE): %d\n", mysqli_affected_rows($con));
// if (mysqli_query($con, $data)) {
// echo "Record deleted successfully";
// } else {
// echo "Error deleting record: " . mysqli_error($con);
// }
mysqli_close($con);
?>
</div>
</div>
</body>
</html>
<?php
include('session_admin.php');
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Admin Place</title>
<style>
* {
box-sizing: border-box;
}
.header {
border: 1px solid green;
padding: 15px;
}
.row::after {
content: "";
clear: both;
display: table;
}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover {
background-color: #111;
}
[class*="col-"] {
float: left;
padding: 15px;
border: 3px solid blue;
}
/* This is allocating layout spaces for how the website is going to be allocated the spaces for different contencts. */
.col-1 {width: 8.33%;}
.col-2 {width: 16.66%;}
.col-3 {width: 25%;}
.col-4 {width: 33.33%;}
.col-5 {width: 41.66%;}
.col-6 {width: 50%;}
.col-7 {width: 58.33%;}
.col-8 {width: 66.66%;}
.col-9 {width: 75%;}
.col-10 {width: 83.33%;}
.col-11 {width: 91.66%;}
.col-12 {width: 100%;}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover:not(.active) {
background-color: #111;
}
.active {
background-color: #4CAF50;
}
@import url(https://fonts.googleapis.com/css?family=Roboto:400,300,600,400italic);
* {
margin: 0;
padding: 0;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-font-smoothing: antialiased;
-o-font-smoothing: antialiased;
font-smoothing: antialiased;
text-rendering: optimizeLegibility;
}
body {
font-family: "Roboto", Helvetica, Arial, sans-serif;
font-weight: 100;
font-size: 15px;
line-height: 30px;
color: #777;
background: #ffffff;
}
.container {
max-width: 400px;
width: 100%;
margin: 0 auto;
position: relative;
}
#contact input[type="Airline"],
#contact input[type="Flight_Number"],
#contact input[type="Departure"],
#contact input[type="Arrival"],
#contact input[type="Time"],
#contact input[type="Morning_AfterNoon_Night"],
#contact input[type="Price"],
#contact button[type="submit"],
#contact button[type="First_Name"],
#contact button[type="Last_Name"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#contact {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#contact h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#contact h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#contact input[type="Airline"],
#contact input[type="Flight_Number"],
#contact input[type="Departure"],
#contact input[type="Arrival"],
#contact input[type="Time"],
#contact input[type="Morning_AfterNoon_Night"],
#contact input[type="Price"],
#contact input[type="First_Name"],
#contact input[type="Last_Name"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#contact input[type="Airline"]:hover,
#contact input[type="Flight_Number"]:hover,
#contact input[type="Departure"]:hover,
#contact input[type="Arrival"]:hover,
#contact input[type="Time"]:hover,
#contact input[type="Morning_AfterNoon_Night"]:hover,
#contact input[type="Price"]:hover,
#contact input[type="First_Name"]:hover,
#contact input[type="Last_Name"]:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#contact textarea {
height: 100px;
max-width: 100%;
resize: none;
}
#contact button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#contact button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#contact button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#contact input:focus,
#contact textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
::-webkit-input-placeholder {
color: #888;
}
:-moz-placeholder {
color: #888;
}
::-moz-placeholder {
color: #888;
}
:-ms-input-placeholder {
color: #888;
}
</style>
</head>
<body>
<?php
$Airline = $Flight_Number = $Departure = $Arrival = $Departure_Time =
$Arrival_Time = $Flight_Time = $Morning_AfterNoon_Night = $Price = "";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$Airline = test_input($_POST["Airline"]);
$Flight_Number = test_input($_POST["Flight_Number"]);
$Departure = test_input($_POST["Departure"]);
$Arrival = test_input($_POST["Arrival"]);
$Departure_Time = test_input($_POST["Departure_Time"]);
$Arrival_Time = test_input($_POST["Arrival_Time"]);
$Flight_Time = test_input($_POST["Flight_Time"]);
$Morning_AfterNoon_Night = test_input($_POST["Morning_AfterNoon_Night"]);
$Price = test_input($_POST["Price"]);
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
<ul>
<li><a href="index1.php">Home</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a href="index1.php">About</a></li>
<li><a class="active" href="admin_place.php">Admin place</a></li>
<li><a href="query_2.php">Customer queries</a></li>
<li><a href="admin_delete_record.php">Deleting record</a></li>
<li><a href="logout_admin.php">Logout</a></li>
</ul>
<div class="row">
<div class="container">
<fieldset>
<form id="contact" method="post" action="<?php $PHP_SELF?>">
<Legend><h1>Inserting flight information</h1></Legend>
<Ledgend>Airline:</legend>
<input placeholder="Airline" type="Airline" name="Airline" tabindex="1" required autofocus/>
<br>
<Ledgend>Flight Number:</legend>
<input placeholder="Flight Number" type="Flight_Number" name="Flight_Number" tabindex="1" required autofocus/>
<br>
<Ledgend>Departure:</legend>
<input placeholder="Departure" type="Departure" name="Departure" tabindex="2" required style="text-transform:uppercase" />
<br>
<Ledgend>Arrival:</legend>
<input placeholder="Arrival" type="Arrival" name="Arrival" tabindex="2" required style="text-transform:uppercase" />
<br>
<Ledgend>Departure Time:</legend>
<input placeholder="Departure Time" type="Time" name="Departure_Time" tabindex="2" required/>
<br>
<Ledgend>Arrival Time:</legend>
<input placeholder="Arrival Time" type="Time" name="Arrival_Time" tabindex="2" required/>
<br>
<Ledgend>Flight Time:</legend>
<input placeholder="Flight Time" type="Time" name="Flight_Time" tabindex="2" required/>
<br>
<Ledgend>Morning, Afternoon or Night:</legend>
<input placeholder="Morning, Afternoon or Night" type="Morning_AfterNoon_Night" name="Morning_AfterNoon_Night" tabindex="1" required autofocus/>
<br>
<Ledgend>Price:</legend>
<input placeholder="Price" type="Price" name="Price" tabindex="1" required autofocus/>
<br>
<input type="submit" name="submit" value="Submit" />
</form>
<?php
#echo "Insert new user";
// connect to the database
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$Departure = strtoupper($_POST['Departure']);
$Arrival = strtoupper($_POST['Arrival']);
$data = mysqli_query($con, "INSERT INTO FlightData (Airline, Flight_Number, Departure, Arrival,
Departure_Time, Arrival_Time, Flight_Time, Morning_AfterNoon_Night, Price)
VALUES ('$Airline', '$Flight_Number', '$Departure', '$Arrival', '$Departure_Time', '$Arrival_Time',
'$Flight_Time', '$Morning_AfterNoon_Night', '$Price')");
mysqli_close($con);
?>
</div>
</div>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>index</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css" href="css2.css">
<script defer src="mainjs.js"></script>
<style>
.container {
max-width: 600px;
margin: 0 auto;
position: relative;
}
#search input[type="departure"],
#search input[type="arrival"],
#search input[type="class"],
#search input[type="date"],
#search input[type="date"],
#search input[type="filters"],
#search button[type="submit"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#search {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#search h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#search h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#search input[type="departure"],
#search input[type="arrival"],
#search input[type="class"],
#search input[type="date"],
#search input[type="date"],
#search input[type="filters"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#search input[type="departure"]:hover,
#search input[type="arrival"]:hover,
#search input[type="class"],
#search input[type="date"]:hover,
#search input[type="date"]:hover,
#search input[type="filters"]:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#search button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#search button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#search button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#search input:focus,
#search textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
</style>
</head>
<body>
<ul>
<li><a href="index.php">Home</a></li>
<li><a class="active" href="booking_page.php">Booking</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a href="user_login.php">Login</a></li>
<li><a href="loginform_for_admin_2.php">Admin login</a></li>
</ul>
<div class="row">
<div class="container">
<fieldset>
<form id="search" method="post" action="<?php $PHP_SELF?>">
<legend><h1>You may search your flights details</h1></legend>
<legend>Please enter your departure and arrival point:</legend>
<br>
<label for="departure">departure: </label>
<input id="departure" placeholder="departure" type="departure" name="departure" tabindex="1" required autofocus style="text-transform:uppercase" />
<br>
<label for="arrival">arrival: </label>
<input id="arrival" placeholder="arrival" type="arrival" name="arrival" tabindex="2" required required autofocus style="text-transform:uppercase" />
<br>
<legend>Please select your class:</legend>
<select>
<option type="class" value="economy">Economy</option>
<option type="class" value="business">Business</option>
<option type="class" value="first">First</option>
</select>
<br>
<legend>Please select your date:</legend>
<label for="start">Start: </label>
<input type="date" id="start" name="trip_going" value="yyyy-mm-dd" min="2018-01-01" max="9000-12-21" />
<br>
<label for="end">End: </label>
<input type="date" id="end" name="trip_back" value="yyyy-mm-dd" min="2018-01-01" max="9000-12-21" />
<br>
<legend>Filter:</legend>
<input type="checkbox" name="check_list[]" value="Morning"><label>Morning</label><br/>
<input type="checkbox" name="check_list[]" value="Afternoon"><label>Afternoon</label><br/>
<input type="checkbox" name="check_list[]" value="Night"><label>Night</label><br/>
<!-- <legend>Cost filter:</legend>
<input type="radio" name="radio_list[]" value="htolcost"><label>Hight to low cost</label><br/>
<input type="radio" name="radio_list[]" value="ltohcost"><label>Low to high cost</label><br/> -->
<!-- <input type="radio" name="cost_order_high_to_low" value="TRUE" checked>TRUE
<input type="radio" name="cost_order_high_to_low" value="FALSE">FALSE
<input type="radio" name="cost_order_low_to_high" value="TRUE" checked>TRUE
<input type="radio" name="cost_order_low_to_high" value="FALSE">FALSE -->
<legend>Cost Filter</legend>
<input name="radio" type="radio" value="htolcost">Hight to low cost
<br>
<input name="radio" type="radio" value="ltohcost">Low to high cost
<br>
<input type="hidden" name="flight_search" value="yes" />
<input type="submit" name="submit" class="button7" value="Search" />
</form>
<?php
//This is only displayed if the user submitted the form
if (isset($_POST['flight_search'])){
echo "<h2>Results</h2><p>";
//If the user did not enter a search term, they receive an error
if ($_POST['departure'] and $_POST['arrival']== ""){
echo "<p>Please enter a search term";
exit;
}
// Otherwise we connect to the database
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno()){
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$departure = ($_POST["departure"]);
$arrival = ($_POST["arrival"]);
$date_going = ($_POST["trip_going"]);
$date_back = ($_POST["trip_back"]);
}
//echo "$departure";
//echo "$arrival";
//Now we search for our search term, in the field the user specified
//if Morning_AfterNoon_Night = Morning
//$data = mysqli_query($con, "SELECT * FROM FlightData WHERE departure = '$departure' AND arrival = '$arrival'");
$int = 0;
foreach ($_POST['check_list'] as $select){
if ($int > 0){
$filter = $filter . " or Morning_AfterNoon_Night ='" . $select . "'" ;
}
else {
$filter = " and Morning_AfterNoon_Night ='" . $select . "'" ;
}
$int = $int + 1;
}
//$a = $a . ")";
if(isset($_POST['radio'])){
echo "You have selected :".$_POST['radio'];
}
if ($_POST['radio'] === 'htolcost'){
$order = " ORDER BY Price DESC" ;
}
else {
$order = " ORDER BY Price" ;
}
//echo "SELECT * FROM FlightData WHERE departure = '$departure' AND arrival = '$arrival' " . "$a";
//$data = mysqli_query($con, "SELECT * FROM FlightData WHERE departure = '$departure' AND arrival = '$arrival'");
$data = mysqli_query($con, "SELECT * FROM FlightData WHERE departure = '$departure' AND arrival = '$arrival' " . "$filter" . "$order");
//And display the results
while($row = mysqli_fetch_array( $data )){
echo "$row[1]". " " ."$row[2]". " " . "$row[3]". " " . "$row[4]". " " . "$row[5]". " " . "$row[6]". " " . "$row[7]". " " . "$row[8]". " " . "$row[9]" . " " . "$date_going". " " . "$date_back". " " ."<a href='loginform2.php?Flight_Id=$row[0]' >". "SELECT" ."</a>";
echo "<br>";
}
//This counts the number or results. If there aren't any, it gives the user a "no match" message
$anymatches=mysqli_num_rows($data);
if ($anymatches == 0){
echo "Sorry, but we can not find an entry to match your query<br><br>";
}
//And reminds the user what they searched for
echo "<b>Searched For:</b> " . "$find";
}
//break;
if (isset($_GET['Flight_Id#'])) {
$Flight_Id = $_GET['Flight_Id'];
echo $Flight_Id;
}
?>
</fieldset>
</div>
<div class="social twitter">
<a href="#" target="_blank"><i class="fa fa-twitter fa-2x"></i></a>
</div>
<div class="social instagram">
<a href="#" target="_blank"><i class="fa fa-instagram fa-2x"></i></a>
</div>
<div class="social facebook">
<a href="#" target="_blank"><i class="fa fa-facebook fa-2x"></i></a>
</div>
</div>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Contact</title>
<link rel="stylesheet" type="text/css" href="css2.css">
<style>
#contact input[type="text"],
#contact input[type="email"],
#contact textarea,
#contact button[type="submit"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#contact {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#contact h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#contact h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#contact input[type="text"],
#contact input[type="email"],
#contact textarea {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#contact input[type="text"]:hover,
#contact input[type="email"]:hover,
#contact textarea:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#contact textarea {
height: 100px;
max-width: 100%;
resize: none;
}
#contact button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#contact button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#contact button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#contact input:focus,
#contact textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
</style>
</head>
<body>
<!-- <script id="__bs_script__">//<![CDATA[
document.write("<script async src='/browser-sync/browser-sync-client.js?v=2.26.7'><\/script>".replace("HOST", location.hostname));
</script> -->
<ul>
<li><a href="index.php">Home</a></li>
<li><a href="booking_page.php">Booking</a></li>
<li><a class="active" href="contact.php">Contact</a></li>
<li><a href="user_login.php">Login</a></li>
<li><a href="loginform_for_admin_2.php">Admin login</a></li>
</ul>
<?php
$Contact_Name = $Email = $Subject = $Message = "";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$Contact_Name = test_input($_POST["Contact_Name"]);
$Email = test_input($_POST["Email"]);
$Subject = test_input($_POST["Subject"]);
$Message = test_input($_POST["Message"]);
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
<div class="row">
<div class="container">
<fieldset>
<form id="contact" action="" method="post">
<h3>Contact</h3>
<fieldset>
<label for="Contact_Name">Please enter your name: </label>
<input placeholder="Your name" type="text" name="Contact_Name" tabindex="1" required autofocus>
</fieldset>
<fieldset>
<label for="Email">Please enter your email address: </label>
<input placeholder="Your Email Address" type="email" name="Email" tabindex="2" required>
</fieldset>
<fieldset>
<legend>Please select your subject:</legend>
<select name="Subject">
<option value="Reporting problems in the website">Reporting problems in the website</option>
<option value="Questions, queries and problems using the website">Questions, queries and problems using the website</option>
<option value="Request">Request in the website</option>
<option value="Cancelling a flight">Cancelling a flight</option>
</select>
</fieldset>
<fieldset>
<legend>Please type in your message:</legend>
<textarea placeholder="Type your message here...." name="Message" tabindex="5" required></textarea>
</fieldset>
<fieldset>
<button name="submit" type="submit" id="contact-submit" class="button7" data-submit="...Sending">Submit</button>
</fieldset>
</form>
</fieldset>
</div>
<?php
if(isset($_POST['submit'])){
$selected_val = $_POST['Subject']; // Storing Selected Value In Variable
echo "You have selected :" .$selected_val; // Displaying Selected Value
}
?>
<?php
// connect to the database
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$data = mysqli_query($con, "INSERT INTO Contact (Contact_Name, Email, Subject, Message)
VALUES ('$Contact_Name', '$Email', '$Subject', '$Message')");
mysqli_close($con);
echo "Your input:::::::::<br>";
echo "".$Contact_Name. "<br>";
echo "".$Email. "<br>";
echo "".$Subject. "<br>";
echo "".$Message. "<br>";
?>
</div>
<!-- social media block -->
<div class="social twitter">
<a href="#" target="_blank"><i class="fa fa-twitter fa-2x"></i></a>
</div>
<div class="social instagram">
<a href="#" target="_blank"><i class="fa fa-instagram fa-2x"></i></a>
</div>
<div class="social facebook">
<a href="#" target="_blank"><i class="fa fa-facebook fa-2x"></i></a>
</div>
</body>
</html>
@import url('https://fonts.googleapis.com/css?family=Montserrat:400,800');
* {
box-sizing: border-box;
}
body {
font-family: 'Montserrat', sans-serif;
background: #f6f5f7;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
height: 100vh;
margin: -20px 0 50px;
}
h1 {
font-weight: bold;
margin: 0;
}
p {
font-size: 14px;
font-weight: 100;
line-height: 20px;
letter-spacing: .5px;
margin: 20px 0 30px;
}
span {
font-size: 12px;
}
a {
color: #333;
font-size: 14px;
text-decoration: none;
margin: 15px 0;
}
.container {
background: #fff;
border-radius: 10px;
box-shadow: 0 14px 28px rgba(0, 0, 0, .25), 0 10px 10px rgba(0, 0, 0, .22);
position: relative;
overflow: hidden;
width: 768px;
max-width: 100%;
min-height: 480px;
}
.form-container form {
background: #fff;
display: flex;
flex-direction: column;
padding: 0 50px;
height: 100%;
justify-content: center;
align-items: center;
text-align: center;
}
.form-container input {
background: #eee;
border: none;
padding: 12px 15px;
margin: 8px 0;
width: 100%;
}
button {
border-radius: 20px;
border: 1px solid #DE584F;
background: #DE584F;
color: #fff;
font-size: 12px;
font-weight: bold;
padding: 12px 45px;
letter-spacing: 1px;
text-transform: uppercase;
transition: transform 80ms ease-in;
}
button:active {
transform: scale(.95);
}
button:focus {
outline: none;
}
button.ghost {
background: transparent;
border-color: #fff;
}
.form-container {
position: absolute;
top: 0;
height: 100%;
transition: all .6s ease-in-out;
}
.sign-in-container {
left: 0;
width: 50%;
z-index: 2;
}
.sign-up-container {
left: 0;
width: 50%;
z-index: 1;
opacity: 0;
}
.overlay-container {
position: absolute;
top: 0;
left: 50%;
width: 50%;
height: 100%;
overflow: hidden;
transition: transform .6s ease-in-out;
z-index: 100;
}
.overlay {
background: #ff416c;
background: linear-gradient(to top, #DE584F, rgb(165, 56, 48)) no-repeat 0 0 / cover;
color: #fff;
position: relative;
left: -100%;
height: 100%;
width: 200%;
transform: translateY(0);
transition: transform .6s ease-in-out;
}
.overlay-panel {
position: absolute;
top: 0;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
padding: 0 40px;
height: 100%;
width: 50%;
text-align: center;
transform: translateY(0);
transition: transform .6s ease-in-out;
}
.overlay-right {
right: 0;
transform: translateY(0);
}
.overlay-left {
transform: translateY(-20%);
}
/* Move signin to right */
.container.right-panel-active .sign-in-container {
transform: translateY(100%);
}
/* Move overlay to left */
.container.right-panel-active .overlay-container {
transform: translateX(-100%);
}
/* Bring signup over signin */
.container.right-panel-active .sign-up-container {
transform: translateX(100%);
opacity: 1;
z-index: 5;
}
/* Move overlay back to right */
.container.right-panel-active .overlay {
transform: translateX(50%);
}
/* Bring back the text to center */
.container.right-panel-active .overlay-left {
transform: translateY(0);
}
/* Same effect for right */
.container.right-panel-active .overlay-right {
transform: translateY(20%);
}
@charset "UTF-8";
@import url(https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css);
* {
box-sizing: border-box;
}
/* .social a {
text-align: center;
width: 52px;
height: 52px;
float: left;
background: #fff;
border: 1px solid #ccc;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), inset 0 0 50px rgba(0, 0, 0, 0.1);
border-radius: 24px;
margin: 0 10px 10px 0;
padding: 6px;
color: #000;
}
.twitter a:hover {
background: #00acee;
color: #fff;
}
.instagram a:hover {
background: #3f729b;
color: #fff;
}
.facebook a:hover {
background: #3b5998;
color: #fff;
} */
.header {
border: 1px solid #DE584F;
padding: 15px;
}
.row::after {
content: "";
clear: both;
display: table;
}
[class*="col-"] {
float: left;
padding: 15px;
}
/* This is allocating layout spaces for how the website is going to be allocated the spaces for different contencts. */
.col-1 {width: 8.33%;}
.col-2 {width: 16.66%;}
.col-3 {width: 25%;}
.col-4 {width: 33.33%;}
.col-5 {width: 41.66%;}
.col-6 {width: 50%;}
.col-7 {width: 58.33%;}
.col-8 {width: 66.66%;}
.col-9 {width: 75%;}
.col-10 {width: 83.33%;}
.col-11 {width: 91.66%;}
.col-12 {width: 100%;}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover:not(.active) {
background-color: #111;
}
.active {
background-color: #DE584F;
}
/* @import url(https://fonts.googleapis.com/css?family=Roboto:400,300,600,400italic);
* {
margin: 0;
padding: 0;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-font-smoothing: antialiased;
-o-font-smoothing: antialiased;
font-smoothing: antialiased;
text-rendering: optimizeLegibility;
} */
body {
font-family: 'Montserrat', sans-serif;
background: #f6f5f7;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
height: 100vh;
margin: -20px 0 50px;
}
h1 {
font-weight: bold;
margin: 0;
}
p {
font-size: 14px;
font-weight: 100;
line-height: 20px;
letter-spacing: .5px;
margin: 20px 0 30px;
}
span {
font-size: 12px;
}
a {
color: #333;
font-size: 14px;
text-decoration: none;
margin: 15px 0;
}
.container {
background: #fff;
border-radius: 10px;
box-shadow: 0 14px 28px rgba(0, 0, 0, .25), 0 10px 10px rgba(0, 0, 0, .22);
position: relative;
overflow: hidden;
width: 768px;
max-width: 100%;
min-height: 480px;
}
.form-container form {
background: #fff;
display: flex;
flex-direction: column;
padding: 0 50px;
height: 100%;
justify-content: center;
align-items: center;
text-align: center;
}
.form-container input {
background: #eee;
border: none;
padding: 12px 15px;
margin: 8px 0;
width: 100%;
}
button {
border-radius: 20px;
border: 1px solid #DE584F;
background: #DE584F;
color: #fff;
font-size: 12px;
font-weight: bold;
padding: 12px 45px;
letter-spacing: 1px;
text-transform: uppercase;
transition: transform 80ms ease-in;
}
button:active {
transform: scale(.95);
}
button:focus {
outline: none;
}
button.ghost {
background: transparent;
border-color: #fff;
}
.form-container {
position: absolute;
top: 0;
height: 100%;
transition: all .6s ease-in-out;
}
.sign-in-container {
left: 0;
width: 50%;
z-index: 2;
}
.sign-up-container {
left: 0;
width: 50%;
z-index: 1;
opacity: 0;
}
.overlay-container {
position: absolute;
top: 0;
left: 50%;
width: 50%;
height: 100%;
overflow: hidden;
transition: transform .6s ease-in-out;
z-index: 100;
}
.overlay {
background: #ff416c;
background: linear-gradient(to top, #DE584F, rgb(165, 56, 48)) no-repeat 0 0 / cover;
color: #fff;
position: relative;
left: -100%;
height: 100%;
width: 200%;
transform: translateY(0);
transition: transform .6s ease-in-out;
}
.overlay-panel {
position: absolute;
top: 0;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
padding: 0 40px;
height: 100%;
width: 50%;
text-align: center;
transform: translateY(0);
transition: transform .6s ease-in-out;
}
.overlay-right {
right: 0;
transform: translateY(0);
}
.overlay-left {
transform: translateY(-20%);
}
/* Move signin to right */
.container.right-panel-active .sign-in-container {
transform: translateY(100%);
}
/* Move overlay to left */
.container.right-panel-active .overlay-container {
transform: translateX(-100%);
}
/* Bring signup over signin */
.container.right-panel-active .sign-up-container {
transform: translateX(100%);
opacity: 1;
z-index: 5;
}
/* Move overlay back to right */
.container.right-panel-active .overlay {
transform: translateX(50%);
}
/* Bring back the text to center */
.container.right-panel-active .overlay-left {
transform: translateY(0);
}
/* Same effect for right */
.container.right-panel-active .overlay-right {
transform: translateY(20%);
}
::-webkit-input-placeholder {
color: #888;
}
:-moz-placeholder {
color: #888;
}
::-moz-placeholder {
color: #888;
}
:-ms-input-placeholder {
color: #888;
}
@charset "UTF-8";
@import url(https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css);
* {
box-sizing: border-box;
}
/* .header {
border: 1px solid #DE584F;
padding: 15px;
} */
.social a {
text-align: center;
width: 52px;
height: 52px;
float: left;
background: #fff;
border: 1px solid #ccc;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), inset 0 0 50px rgba(0, 0, 0, 0.1);
border-radius: 24px;
margin: 0 10px 10px 0;
padding: 6px;
color: #000;
}
.twitter a:hover {
background: #00acee;
color: #fff;
}
.instagram a:hover {
background: #3f729b;
color: #fff;
}
.facebook a:hover {
background: #3b5998;
color: #fff;
}
.header {
border: 1px solid #DE584F;
padding: 15px;
}
.row::after {
content: "";
clear: both;
display: table;
}
/* .row::after {
content: "";
clear: both;
display: table;
} */
/* ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover {
background-color: #111;
} */
[class*="col-"] {
float: left;
padding: 15px;
}
/* This is allocating layout spaces for how the website is going to be allocated the spaces for different contencts. */
.col-1 {
width: 8.33%;
}
.col-2 {
width: 16.66%;
}
.col-3 {
width: 25%;
}
.col-4 {
width: 33.33%;
}
.col-5 {
width: 41.66%;
}
.col-6 {
width: 50%;
}
.col-7 {
width: 58.33%;
}
.col-8 {
width: 66.66%;
}
.col-9 {
width: 75%;
}
.col-10 {
width: 83.33%;
}
.col-11 {
width: 91.66%;
}
.col-12 {
width: 100%;
}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover:not(.active) {
background-color: #111;
}
.active {
background-color: #DE584F;
}
@import url(https://fonts.googleapis.com/css?family=Roboto:400,300,600,400italic);
* {
margin: 0;
padding: 0;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-font-smoothing: antialiased;
-o-font-smoothing: antialiased;
font-smoothing: antialiased;
text-rendering: optimizeLegibility;
}
body {
font-family: "Roboto", Helvetica, Arial, sans-serif;
font-weight: 100;
font-size: 20px;
line-height: 40px;
color: #777;
height: 200vh;
background-image: linear-gradient(to top, gray, white 40%);
}
.container {
max-width: 600px;
margin: 0 auto;
position: relative;
}
::-webkit-input-placeholder {
color: #888;
}
:-moz-placeholder {
color: #888;
}
::-moz-placeholder {
color: #888;
}
:-ms-input-placeholder {
color: #888;
}
[class*="button7"] {
background-color: #DE584F;
}
.button7 {
font-weight: 700;
color: white;
text-decoration: none;
padding: .8em 2em calc(.8em + 3px);
border-radius: 3px;
background: #DE584F(64, 199, 129);
box-shadow: 0 -3px #DE584F(53, 167, 110) inset;
transition: 0.2s;
}
.button7:hover {
background: #DE584F(206, 211, 208);
}
.button7:active {
background: #DE584F(206, 211, 208);
box-shadow: 0 3px rgb(33, 147, 90) inset;
}
\ No newline at end of file
<svg id="Слой_1" data-name="Слой 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 229 118.5"><defs><style>.cls-1,.cls-2{fill:#de584f;}.cls-2,.cls-5{stroke:#fff;}.cls-2,.cls-3,.cls-5{stroke-miterlimit:10;}.cls-2,.cls-3{stroke-width:2px;}.cls-3,.cls-4{fill:#fff;}.cls-3{stroke:#de584f;}.cls-5{fill:none;stroke-width:4px;}</style></defs><title>airplaneticketsbooking1</title><rect class="cls-1" width="229" height="118.5"/><rect class="cls-2" x="76.24" y="44.35" width="36.32" height="26.67"/><rect class="cls-3" x="112.56" y="44.35" width="36.32" height="26.67"/><polygon class="cls-4" points="98.11 46.82 98.11 49.22 91.79 49.22 91.79 68.42 88.75 68.42 88.75 49.22 82.43 49.22 82.43 46.82 98.11 46.82"/><path class="cls-1" d="M274.09,221.38a6.05,6.05,0,0,1-6,6h-7.69V205.69h7.88a4.89,4.89,0,0,1,4.88,4.88,4.87,4.87,0,0,1-4.19,4.82A6,6,0,0,1,274.09,221.38Z" transform="translate(-132.3 -158.88)"/><path class="cls-4" d="M271.25,221.6a4.11,4.11,0,0,1-4.11,4.1H263.2V217.5h3.95A4.11,4.11,0,0,1,271.25,221.6Z" transform="translate(-132.3 -158.88)"/><path class="cls-4" d="M270.44,211.14a3.58,3.58,0,0,1-3.58,3.58H263.2v-7.16h3.66A3.59,3.59,0,0,1,270.44,211.14Z" transform="translate(-132.3 -158.88)"/><path class="cls-5" d="M208.54,234.29h72.64c.87-.63,9.24-6.84,9.28-17.73,0-1.38-.14-12.14-9.28-17.79a20.21,20.21,0,0,0-20.82,0" transform="translate(-132.3 -158.88)"/><path class="cls-4" d="M206.49,202.84l.49-.16c.44-.15.55-.19.61-.31a.67.67,0,0,0-.06-.51c-.06-.18-.13-.37-.31-.43s-.15,0-.48.08c.07-.37.14-.75.21-1.15l.45-.14c.44-.15.55-.19.61-.31a.67.67,0,0,0-.06-.51c-.06-.18-.13-.37-.31-.43s-.14,0-.46.07l.24-1.39L211.9,196a2.67,2.67,0,0,0,1.22-.87,2.74,2.74,0,0,0,.54-1.43,2.9,2.9,0,0,0-1.3-.62,2.81,2.81,0,0,0-1.49.13l-4.46,1.65-1.09-.91c.31-.12.36-.18.39-.24a.66.66,0,0,0,0-.53c-.07-.18-.13-.36-.29-.43s-.23,0-.66.16l-.43.18-.91-.74c.33-.13.39-.19.42-.26a.66.66,0,0,0,0-.53c-.07-.18-.13-.36-.29-.43s-.23,0-.66.16l-.48.2c-3.38-2.69-4.48-3.29-4.66-3.1s.66,1.22,3.22,5.19c.68,1,1.24,1.94,1.64,2.58L197.85,198l-3.24-1.4a.85.85,0,0,0-.74.58l2.82,2.69.29.06-.18.23L196.4,204a.85.85,0,0,0,.94,0l1.56-3.17,4.73-1.64c.11.75.26,1.79.43,3,.62,4.68.64,6,.91,6S205.67,207.08,206.49,202.84Z" transform="translate(-132.3 -158.88)"/><rect class="cls-1" x="111.85" y="43.72" width="0.71" height="28.05"/><rect class="cls-4" x="112.79" y="43.93" width="0.66" height="27.92"/><polygon class="cls-4" points="112.23 38.35 112.23 59.04 106.9 58.99 103.65 68.55 99.59 68.55 109.83 38.35 112.23 38.35"/><polygon class="cls-1" points="124.88 68.55 120.77 68.55 117.36 59.09 112.23 59.04 112.23 38.35 114.69 38.35 124.88 68.55"/><polygon class="cls-1" points="112.23 41.58 112.23 55.77 107.65 55.77 112.23 41.58"/><polygon class="cls-4" points="116.82 55.77 112.23 55.77 112.23 41.58 116.82 55.77"/><rect class="cls-4" x="113.45" y="59.07" width="3.75" height="10.93"/></svg>
\ No newline at end of file
img/best.png

659 Bytes

This diff is collapsed. Click to expand it.
img/info.png

313 Bytes

img/jp1.jpg

67.5 KB

img/jp2.jpg

67.7 KB

img/l.jpg

66.8 KB

img/ny1.jpg

92.8 KB

img/ny2.jpg

46.4 KB

img/p1.jpg

66.4 KB

img/pic.png

599 Bytes

This diff is collapsed. Click to expand it.
img/zb.jpg

34.2 KB

This diff is collapsed. Click to expand it.
$(function() {
var Accordion = function(el, multiple) {
this.el = el || {};
// more then one submenu open?
this.multiple = multiple || false;
var dropdownlink = this.el.find('.dropdownlink');
dropdownlink.on('click', { el: this.el, multiple: this.multiple },
this.dropdown);
};
Accordion.prototype.dropdown = function(e) {
var $el = e.data.el,
$this = $(this),
//this is the ul.submenuItems
$next = $this.next();
$next.slideToggle();
$this.parent().toggleClass('open');
if (!e.data.multiple) {
//show only one menu at the same time
$el.find('.submenuItems').not($next).slideUp().parent().removeClass('open');
}
}
var accordion = new Accordion($('.accordion-menu'), false);
})
\ No newline at end of file
const signUpButton = document.getElementById('signUp');
const signInButton = document.getElementById('signIn');
const container = document.getElementById('container');
signUpButton.addEventListener('click', () =>
container.classList.add('right-panel-active'));
signInButton.addEventListener('click', () =>
container.classList.remove('right-panel-active'));
// Part with validation
const departure = document.getElementById('departure')
const arrival = document.getElementById('arrival')
const form = document.getElementById('form')
const errorElement = document.getElementById('error')
const FirstName = document.getElementById('FirsName')
const LastName = document.getElementById('LastName')
const username = document.getElementById('username')
const password = document.getElementById('password')
form.addEventListener('submit', (e) => {
let messages = []
if (departure.value === '' || departure.value == null) {
messages.push('Departure is required')
}
if (arrival.value === '' || arrival.value == null) {
messages.push('Arrival is required')
}
if (FirstName.value === '' || FirstName.value == null) {
messages.push('First-Name is required')
}
if (LastName.value === '' || LastName.value == null) {
messages.push('Last-Name is required')
}
if (username.value === '' || username.value == null) {
messages.push('Username is required')
}
if (password.value.length <= 6) {
messages.push('Password must be longer than 6 characters ')
}
if (messages.length > 0) {
e.preventDefault()
errorElement.innerText = messages.join(', ')
}
})
\ No newline at end of file
var slideIndex = 1;
showSlides(slideIndex);
function plusSlides(n) {
showSlides(slideIndex += n);
}
function showSlides(n) {
var i;
var slides = document.getElementsByClassName("mySlides");
var dots = document.getElementsByClassName("dot");
if (n > slides.length) {
slideIndex = 1
}
if (n < 1) {
slideIndex = slides.length
}
for (i = 0; i < slides.length; i++) {
slides[i].style.display = "none";
}
for (i = 0; i < dots.length; i++) {
dots[i].className = dots[i].className.replace(" active", "");
}
slides[slideIndex - 1].style.display = "block";
dots[slideIndex - 1].className += " active";
}
var slideIndex = 0;
showSlides();
function showSlides() {
var i;
var slides = document.getElementsByClassName("mySlides");
for (i = 0; i < slides.length; i++) {
slides[i].style.display = "none";
}
slideIndex++;
if (slideIndex > slides.length) {
slideIndex = 1;
}
slides[slideIndex - 1].style.display = "block";
setTimeout(showSlides, 3000);
}
\ No newline at end of file
<?php
session_start(); // Starting Session
$error=''; // Variable To Store Error Message
if (isset($_POST['submit'])) {
if (empty($_POST['username']) || empty($_POST['password'])) {
$error = "username or password is invalid";
}
else
{
// Define $username and $password
$username=$_POST['username'];
$password=$_POST['password'];
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost, root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
// To protect MySQL injection for Security purpose
$username = stripslashes($username);
$password = stripslashes($password);
//$username = mysqli_real_escape_string($username);
//$password = mysqli_real_escape_string($password);
// Selecting Database
$db = mysqli_select_db($con, "Airline_Booking");
// SQL query to fetch information of registerd users and finds user match.
$query = mysqli_query($con, "SELECT username and password FROM User_register WHERE username='$username' AND password='$password'");
$rows = mysqli_num_rows($query);
if ($rows == 1) {
$_SESSION['login_user']=$username; // Initializing Session
header("location: payment1.php"); // Redirecting To Other Page
} else {
$error = ":::username or password is invalid";
}
mysqli_close($con); // Closing Connection
}
}
?>
<?php
session_start(); // Starting Session
$error=''; // Variable To Store Error Message
if (isset($_POST['submit'])) {
if (empty($_POST['username']) || empty($_POST['password'])) {
$error = "username or password is invalid";
}
else
{
// Define $username and $password
$username=$_POST['username'];
$password=$_POST['password'];
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
// To protect MySQL injection for Security purpose
$username = stripslashes($username);
$password = stripslashes($password);
//$username = mysqli_real_escape_string($username);
//$password = mysqli_real_escape_string($password);
// Selecting Database
$db = mysqli_select_db($con, "Airline_Booking");
// SQL query to fetch information of registerd users and finds user match.
$query = mysqli_query($con, "SELECT username and password FROM Admin WHERE username='$username' AND password='$password'");
$rows = mysqli_num_rows($query);
if ($rows == 1) {
$_SESSION['login_user']=$username; // Initializing Session
header("location: admin_place.php"); // Redirecting To Other Page
} else {
$error = ":::username or password is invalid";
}
mysqli_close($con); // Closing Connection
}
}
?>
<?php
session_start(); // Starting Session
$error=''; // Variable To Store Error Message
if (isset($_POST['submit'])) {
if (empty($_POST['username']) || empty($_POST['password'])) {
$error = "username or password is invalid";
}
else
{
// Define $username and $password
$username=$_POST['username'];
$password=$_POST['password'];
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
// To protect MySQL injection for Security purpose
$username = stripslashes($username);
$password = stripslashes($password);
//$username = mysqli_real_escape_string($username);
//$password = mysqli_real_escape_string($password);
// Selecting Database
$db = mysqli_select_db($con, "Airline_Booking");
// SQL query to fetch information of registerd users and finds user match.
$query = mysqli_query($con, "SELECT username and password FROM User_register WHERE username='$username' AND password='$password'");
$rows = mysqli_num_rows($query);
if ($rows == 1) {
$_SESSION['login_user']=$username; // Initializing Session
header("location: user_flight_search.php"); // Redirecting To Other Page
} else {
$error = ":::username or password is invalid";
}
mysqli_close($con); // Closing Connection
}
}
?>
<?php
include('login.php'); // Includes Login Script
if(isset($_SESSION['login_user'])){
header("location: payment1.php");
}
?>
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Payment</title>
<link rel="stylesheet" type="text/css" href="css2.css">
<style>
#login input[type="username"],
#login input[type="password"],
#login button[type="submit"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#login {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#login h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#login h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#login input[type="username"],
#login input[type="password"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#login input[type="username"]:hover,
#login input[type="password"]:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#login textarea {
height: 100px;
max-width: 100%;
resize: none;
}
#login button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#login button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#login button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#login input:focus,
#login textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
::-webkit-input-placeholder {
color: #888;
}
:-moz-placeholder {
color: #888;
}
::-moz-placeholder {
color: #888;
}
:-ms-input-placeholder {
color: #888;
}
</style>
</head>
<body>
<ul>
<li><a href="index.php">Home</a></li>
<li><a class="active" href="booking_page.php">Booking</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a href="loginform_user_2.php">Login</a></li>
<li><a href="loginform_for_admin_2.php">Admin login</a></li>
</ul>
<div class="row">
<div class="container">
<fieldset>
<form id="login" action="" method="post">
<label>Username:</label>
<input id="username" name="username" placeholder="Username" type="username">
<label>Password:</label>
<input id="password" name="password" placeholder="Password" type="password">
<input name="submit" type="submit" class="button7" value="Login">
<span><?php echo $error; ?></span>
</form>
<?php
// $con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
//
// // Check connection
// if (mysqli_connect_errno()){
// echo "Failed to connect to MySQL: " . mysqli_connect_error();
// }
//
// if ($_SERVER["REQUEST_METHOD"] == "POST") {
// $username = ($_POST["username"]);
// $password = ($_POST["password"]);
// }
//
// $data = mysqli_query($con, "SELECT MemberID FROM User_register WHERE username = '$username' AND password = '$password' ");
// MemberID = $row[0]
// if (isset($_GET['MemberID'])) {
// $MemberID = $_GET['MemberID'];
// echo $MemberID;
// }
// session_start();
// if (isset($_GET['MemberID'])) {
// $MemberID = $_GET['MemberID'];
// $_SESSION['MemberID'] = $MemberID;
// }
session_start();
if (isset($_POST['username'])) {
$username_value = $_POST['username'];
$_SESSION['username'] = $username_value;
}
session_start();
if (isset($_POST['password'])) {
$password_value = $_POST['password'];
$_SESSION['password'] = $password_value;
}
$var_value = $_GET['Flight_Id'];
echo "Your flight ID is ".$var_value."." ;
session_start();
if (isset($_GET['Flight_Id'])) {
$Flight_Id = $_GET['Flight_Id'];
$_SESSION['Flight_Id'] = $Flight_Id;
}
?>
<h3><legend>Register</legend></h3>
<label>If you do not have username and password, please register by clicking</label>
<a href="registration.php" class="button7" target="_blank">Register</a>
<!-- <p>If you do not have username and password, please register by clicking
<a href="registration.php" class="button7" target="_blank">Register</a> -->
</fieldset>
</div>
</div>
</body>
</html>
<?php
include('login_admin.php'); // Includes Login Script
if(isset($_SESSION['login_user'])){
header("location: admin_place.php");
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Login Admin</title>
<link rel="stylesheet" type="text/css" href="css2.css">
<style>
#login input[type="username"],
#login input[type="password"],
#login button[type="submit"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#login {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#login h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#login h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#login input[type="username"],
#login input[type="password"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#login input[type="username"]:hover,
#login input[type="password"]:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#login textarea {
height: 100px;
max-width: 100%;
resize: none;
}
#login button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#login button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#login button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#login input:focus,
#login textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
</style>
</head>
<body>
<ul>
<li><a href="index.php">Home</a></li>
<li><a href="booking_page.php">Booking</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a href="user_login.php">Login</a></li>
<li><a class="active" href="loginform_for_admin_2.php">Admin login</a></li>
</ul>
<div class="container">
<fieldset>
<form id="login" action="" method="post">
<label>Username :</label>
<input id="username" name="username" placeholder="Username" type="username">
<label>Password :</label>
<input id="password" name="password" placeholder="Password" type="password">
<input name="submit" type="submit" class="button7" value=" Login ">
<span><?php echo $error; ?></span>
</form>
</fieldset>
</div>
<!-- social media block -->
<div class="social twitter">
<a href="#" target="_blank"><i class="fa fa-twitter fa-2x"></i></a>
</div>
<div class="social instagram">
<a href="#" target="_blank"><i class="fa fa-instagram fa-2x"></i></a>
</div>
<div class="social facebook">
<a href="#" target="_blank"><i class="fa fa-facebook fa-2x"></i></a>
</div>
</body>
</html>
<?php
include('login.php'); // Includes Login Script
if(isset($_SESSION['login_user'])){
header("location: payment1.php");
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Login</title>
<link rel="stylesheet" type="text/css" href="css2.css">
<style>
#login input[type="username"],
#login input[type="password"],
#login button[type="submit"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#login {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#login h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#login h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#login input[type="username"],
#login input[type="password"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#login input[type="username"]:hover,
#login input[type="password"]:hover {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#login textarea {
height: 100px;
max-width: 100%;
resize: none;
}
#login button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#login button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#login button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#login input:focus,
#login textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
</style>
</head>
<body>
<ul>
<li><a href="index.php">Home</a></li>
<li><a href="booking_page.php">Booking</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a class="active" href="loginform_user_2.php">Login</a></li>
<li><a href="loginform_for_admin_2.php">Admin login</a></li>
</ul>
<div class="container">
<fieldset>
<form id="login" action="" method="post">
<label>Username :</label>
<input id="username" name="username" placeholder="Username" type="username">
<label>Password :</label>
<input id="password" name="password" placeholder="Password" type="password">
<input name="submit" type="submit" class="button7" value=" Login ">
<span><?php echo $error; ?></span>
</form>
<h3><legend>Register</legend></h3>
<p>If you do not have username and password, please register by clicking<a href="registration.php" class="button7" target="_blank">Register</a></p>
</fieldset>
</div>
</body>
</html>
<?php
session_start();
if(session_destroy()) // Destroying All Sessions
{
header("Location: booking_page.php"); // Redirecting To Home Page
}
?>
<?php
session_start();
if(session_destroy()) // Destroying All Sessions
{
header("Location: loginform_for_admin_2.php"); // Redirecting To Home Page
}
?>
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>payment</title>
<style>
* {
box-sizing: border-box;
}
.header {
border: 1px solid green;
padding: 15px;
}
.row::after {
content: "";
clear: both;
display: table;
}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover {
background-color: #111;
}
[class*="col-"] {
float: left;
padding: 15px;
border: 3px solid blue;
}
/* This is allocating layout spaces for how the website is going to be allocated the spaces for different contencts. */
.col-1 {width: 8.33%;}
.col-2 {width: 16.66%;}
.col-3 {width: 25%;}
.col-4 {width: 33.33%;}
.col-5 {width: 41.66%;}
.col-6 {width: 50%;}
.col-7 {width: 58.33%;}
.col-8 {width: 66.66%;}
.col-9 {width: 75%;}
.col-10 {width: 83.33%;}
.col-11 {width: 91.66%;}
.col-12 {width: 100%;}
ul {
list-style-type: none;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #333;
}
li {
float: left;
}
li a {
display: block;
color: white;
text-align: center;
padding: 14px 16px;
text-decoration: none;
}
li a:hover:not(.active) {
background-color: #111;
}
.active {
background-color: #4CAF50;
}
@import url(https://fonts.googleapis.com/css?family=Roboto:400,300,600,400italic);
* {
margin: 0;
padding: 0;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-font-smoothing: antialiased;
-o-font-smoothing: antialiased;
font-smoothing: antialiased;
text-rendering: optimizeLegibility;
}
body {
font-family: "Roboto", Helvetica, Arial, sans-serif;
font-weight: 100;
font-size: 15px;
line-height: 30px;
color: #777;
background: #ffffff;
}
.container {
max-width: 400px;
width: 100%;
margin: 0 auto;
position: relative;
}
#registration input[type="first_name"],
#registration input[type="last_name"],
#registration input[type="username"],
#registration input[type="password"],
#registration button[type="submit"] {
font: 400 12px/16px "Roboto", Helvetica, Arial, sans-serif;
}
#registration {
background: #F9F9F9;
padding: 25px;
margin: 15px 0;
box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.2), 0 5px 5px 0 rgba(0, 0, 0, 0.24);
}
#registration h3 {
display: block;
font-size: 30px;
font-weight: 300;
margin-bottom: 10px;
}
#registration h4 {
margin: 5px 0 15px;
display: block;
font-size: 13px;
font-weight: 400;
}
fieldset {
border: medium none !important;
margin: 0 0 10px;
min-width: 100%;
padding: 0;
width: 100%;
}
#registration input[type="first_name"],
#registration input[type="last_name"],
#registration input[type="username"],
#registration input[type="password"] {
width: 100%;
border: 1px solid #ccc;
background: #FFF;
margin: 0 0 5px;
padding: 10px;
}
#registration input[type="first_name"]:hover,
#registration input[type="last_name"]:hover,
#registration input[type="username"]:hover,
#registration input[type="password"]:hover, {
-webkit-transition: border-color 0.3s ease-in-out;
-moz-transition: border-color 0.3s ease-in-out;
transition: border-color 0.3s ease-in-out;
border: 1px solid #aaa;
}
#registration button[type="submit"] {
cursor: pointer;
width: 100%;
border: none;
background: #4CAF50;
color: #FFF;
margin: 0 0 5px;
padding: 10px;
font-size: 20px;
}
#registration button[type="submit"]:hover {
background: #43A047;
-webkit-transition: background 0.3s ease-in-out;
-moz-transition: background 0.3s ease-in-out;
transition: background-color 0.3s ease-in-out;
}
#registration button[type="submit"]:active {
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}
#registration input:focus,
#registration textarea:focus {
outline: 0;
border: 1px solid #aaa;
}
::-webkit-input-placeholder {
color: #888;
}
:-moz-placeholder {
color: #888;
}
::-moz-placeholder {
color: #888;
}
:-ms-input-placeholder {
color: #888;
}
</style>
</head>
<body>
<?php
$First_Name = $Last_Name = $username = $Password = "";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$First_Name = test_input($_POST["First_Name"]);
$Last_Name = test_input($_POST["Last_Name"]);
$username = test_input($_POST["username"]);
$Password = test_input($_POST["Password"]);
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
<div class="col-3">
<h1>Logo</h1>
</div>
<div class="col-9">
<h1>Payment and confirmation Webpage</h1>
</div>
<div class="col-12">
<ul>
<li><a class="active" href="index5.php">Home</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a href="index5.php">About</a></li>
</ul>
</div>
<div class="row">
<div class="container">
<fieldset>
<form id="registration" method="post" action="<?php $PHP_SELF?>">
<Legend><h1>Please fill in the form in order to register</h1></Legend>
<Ledgend>Please fill in your details:</legend>
<br>
<label for="first_name">First Name: </label>
<input placeholder="First Name" type="first_name" name="First_Name" tabindex="1" required autofocus/>
<br>
<label for="last_name">Last Name: </label>
<input placeholder="Last Name" type="last_name" name="Last_Name" tabindex="2" required/>
<br>
<p>
<label for="username">username Address: </label>
<input placeholder="username Address" type="username" name="username" tabindex="2" required/>
<br>
<p>
<label for="password">Password: </label>
<input placeholder="Password" type="password" name="Password" tabindex="2" required/>
<br>
<p>
<input type="submit" name="submit" value="Register" />
<br />
<p>Once you have registered, please go back to the login page in order to access the payment page. Please close go back to the login tab from the tab section.</p>
</form>
<?php
#echo "Insert new user";
// connect to the database
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost, root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$data = mysqli_query($con, "INSERT INTO User_register (First_Name, Last_Name, username, Password)
VALUES ('$First_Name', '$Last_Name', '$username', '$Password')");
//mysql_query($sql1, $con);
mysqli_close($con);
echo "Your input:::::::::<br>";
echo "".$First_Name. "<br>";
echo "".$Last_Name. "<br>";
echo "".$username. "<br>";
echo "".$Password. "<br>";
?>
</div>
</body>
</html>
<?php
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
// Selecting Database
$db = mysqli_select_db($con, "Airline_Booking");
session_start();// Starting Session
// Storing Session
$user_check=$_SESSION['login_user'];
// SQL Query To Fetch Complete Information Of User
$ses_sql=mysqli_query($con, "SELECT username FROM User_register WHERE username='$user_check'");
$row = mysqli_fetch_assoc($ses_sql);
$login_session =$row['username'];
if(!isset($login_session)){
mysqli_close($con); // Closing Connection
header('Location: payment1.php'); // Redirecting To Payment Page
}
?>
<?php
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost, root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
// Selecting Database
$db = mysqli_select_db($con, "Airline_Booking");
session_start();// Starting Session
// Storing Session
$user_check=$_SESSION['login_user'];
// SQL Query To Fetch Complete Information Of User
$ses_sql=mysqli_query($con, "SELECT username FROM Admin WHERE username='$user_check'");
$row = mysqli_fetch_assoc($ses_sql);
$login_session =$row['username'];
if(!isset($login_session)){
mysqli_close($con); // Closing Connection
header('Location: admin_place.php'); // Redirecting To Payment Page
}
?>
<?php
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
// Selecting Database
$db = mysqli_select_db($con, "Airline_Booking");
session_start();// Starting Session
// Storing Session
$user_check=$_SESSION['login_user'];
// SQL Query To Fetch Complete Information Of User
$ses_sql=mysqli_query($con, "SELECT username FROM User_register WHERE username='$user_check'");
$row = mysqli_fetch_assoc($ses_sql);
$login_session =$row['username'];
if(!isset($login_session)){
mysqli_close($con); // Closing Connection
header('Location: user_flight_search.php'); // Redirecting To Payment Page
}
?>
<?php
include('login_script_for_user_login.php'); // Includes Login Script
if(isset($_SESSION['login_user'])){
header("location: user_flight_search.php");
}
?>
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.8.1/css/all.css" integrity="sha384-50oBUHEmvpQ+1lW4y57PTFmhCaXp0ML5d60M1M7uH2+nqUivzIebhndOJK28anvf" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="css/stylesheet2.css">
<script defer src="js/mainjs.js"></script>
</head>
<body>
<!--
<ul>
<li><a href="index.php">Home</a></li>
<li><a href="booking_page.php">Booking</a></li>
<li><a href="contact.php">Contact</a></li>
<li><a class="active" href="user_login.php">Login</a></li>
<li><a href="loginform_for_admin_2.php">Admin login</a></li>
</ul>
-->
<?php
$First_Name = $Last_Name = $username = $Password = "";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$First_Name = test_input($_POST["First_Name"]);
$Last_Name = test_input($_POST["Last_Name"]);
$username = test_input($_POST["username"]);
$Password = test_input($_POST["Password"]);
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
<div class="container" id="container">
<div class="form-container sign-up-container">
<form method="post" action="<?php $PHP_SELF?>">
<h1>Create Account</h1>
<div class="social-container">
<a href="#" class="social"><i class="fab fa-facebook fa-2x"></i></a>
<a href="#" class="social"><i class="fab fa-twitter fa-2x"></i></a>
<a href="#" class="social"><i class="fab fa-instagram fa-2x"></i></a>
</div>
<input id="FirstName" placeholder="First Name" type="first_name" name="First_Name" tabindex="1" required autofocus/>
<input id="LastName" placeholder="Last Name" type="last_name" name="Last_Name" tabindex="2" required/>
<input id="username" placeholder="username Address" type="username" name="username" tabindex="2" required/>
<input id="password" placeholder="Password" type="password" name="Password" tabindex="2" required/>
<input type="submit" name="submit" value="Register"/>
</form>
<?php
#echo "Insert new user";
// connect to the database
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$con = mysqli_connect(localhost,root, root, Airline_Booking, 8889);
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$data = mysqli_query($con, "INSERT INTO User_register (First_Name, Last_Name, username, Password)
VALUES ('$First_Name', '$Last_Name', '$username', '$Password')");
//mysql_query($sql1, $con);
mysqli_close($con);
echo "Your input:::::::::<br>";
echo "".$First_Name. "<br>";
echo "".$Last_Name. "<br>";
echo "".$username. "<br>";
echo "".$Password. "<br>";
?>
</div>
<div class="form-container sign-in-container">
<form id="login" action="" method="post">
<h1>Sign In</h1>
<div class="social-container">
<a href="#" class="social"><i class="fab fa-facebook fa-2x"></i></a>
<a href="#" class="social"><i class="fab fa-twitter fa-2x"></i></a>
<a href="#" class="social"><i class="fab fa-instagram fa-2x"></i></a>
</div>
<input id="username" name="username" placeholder="Username" type="email">
<input id="password" name="password" placeholder="Password" type="password">
<input name="submit" type="submit" class="button7" value=" Login ">
<span><?php echo $error; ?></span>
</form>
</div>
<div class="overlay-container">
<div class="overlay">
<div class="overlay-panel overlay-left">
<h1>Welcome Back!</h1>
<p>To keep connected with us please login with your personal info</p>
<button class="ghost" id="signIn">Sign In</button>
</div>
<div class="overlay-panel overlay-right">
<h1>Hello, Friend!</h1>
<p>Enter your personal details and start journey with us</p>
<button class="ghost" id="signUp">Sign Up</button>
</div>
</div>
</div>
</div>
</body>
<script src="js/mainjs.js"></script>
</html>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment