Commit d3d28b35 authored by KRUSHNA ABHIJIT PATIL's avatar KRUSHNA ABHIJIT PATIL

adding

parent 4f8b9ed4
######################################################################################################################################################
------------------------------------------------------------------Welcome to Abhi Cabs----------------------------------------------------------------
######################################################################################################################################################
**********************copy right reserver with Abhi_cabs Any use of the part of code needs the prior permision of the developers**********************
######################################################################################################################################################
-------------------------------------------------------------------------------------------------------------------------------------------------------
#######################################################################################################################################################
This document contains almost-all and import function description and some link to the manuals
HTML :
tags/subtags used => html, body, div, img, h1, form, span, lable, br, b, p, input, button, font, li, ul, nav.
many more may be used but all these basic html tags information can be taken from
https://www.w3schools.com/html/
Some important points/ function/ variables/ properties of the above tags used are :
tag => form :
action: this helps to understand the html file what to do when the uesr click on the submit button.
this means when a user click on the submit button it goes to link discriped in this variable.
method: This attribute specifies how to send form-data (the form-data is sent to the page specified in the action attribute).
The form-data can be sent as URL variables (with method="get") or as HTTP post transaction (with method="post").
autocomplete: this is used as in this project auto complete the text property is used.
this varibale should be declare to "off" if your using it for auto complete the text field.
tag => (can be used for any of the tag):
onclick: This function can be used to do things after the button is clicked or anyupdate is made.
this function calls a javascript function and then javascript code takes the lead on what to do next.
class: this attribute is use to define a tag in the html file which common.
reason for using this is let say we need a box all the time in the html file so writing its style all time
will take lot of time so we use class attribute to solve this problem.
id: this attribute is used when we want to descripe or define a style or a call function to a perticular tag
then to make it uniqe we use this attribute.
other all info can be found on (https://www.w3schools.com/html/)
PHP :
function used :
echo: Lets start with the easy thing it it used as a print statement in PHP
_POST: to get information or we can say serach the name in the string passed to it.
it get the tag for which the name was given as input to it.
test_input: it used to get the information from the text that the user inputs and it stores in a variable
php variable.
_SESSION: one the most important function used in php. it is use to create session in php.
sesions are very important in php as we are loged we start a session and no other session of the same type should
start so this function is import.
very important its a array /dictionary where multiple varibale can be passed between the sessions but must uniqe
for each sessions
for more details use link (https://www.w3schools.com/php/php_sessions.asp)
header: this is used to move to the next url after all the work the current page is done.
mostly important function use in the code has been discribed above
but for more details and for other functions used in the code refer the link below
(https://www.w3schools.com/php/)
MySql :
function used :
mysqli() : This function is use to connect to the database.
So it need host_name, database_name, user_name, password(for the user)
mysqli_query() : this function is use to run the sql query given as a input to it.
for this it connectes to the database and run the query.
mysqli_num_rows() : this function give the number of rows that are the output of the query run on the database.
mysqli_fetch_array() : this function gives the output a array if the input contains and row else output a empty array.
mostly important function use in the code has been discribed above
but for more details and for other functions used in the code refer the link below
(https://www.php.net/manual/en/book.mysqli.php)
CSS :
function used :
animation : this is somthing need to be discibed it is use to change color and for moving tag from one location to other.
for more details refer the link below
(https://www.w3schools.com/css/css3_animations.asp)
refer the link give below for more details
(https://www.w3schools.com/css/)
jQuery :
the important function was used of jquery to complete/ suggestion the text box as we give input for it.
please refer the link below as it is copied direly from there and it is self explanatory
(https://www.w3schools.com/howto/howto_js_autocomplete.asp)
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
PAGE FLOW :
INDEX.PHP
__________________________________________|__________________________________ _________________________________ ___________________
| | | |
DRIVER BUTTON CUSTOMER BUTTON ABOUT_US.PHP CONTACT.PHP
_____________________|____________________ ______________________|___________________
| | | |
LOGIN BUTTON SIGN UP BUTTON LOGIN BUTTON SIGN UP BUTTON
| | | |
DRIVER.PHP DRIVER_SIGN_UP.PHP MAIN.PHP CUSTOMER_SIGN_UP.PHP
| | | |
CREATE RIDE BUTTON (after filling the form correctly) (after fill the "FROM" and (after filling the form crrectly)
| | "TO" and then click on |
(after filling the form correctly) DRIVER.PHP search display the cabs) MAIN.PHP
| |
DRIVER.PHP (after selecting the ride
| click "go" to book the ride)
LOGOUT BUTTON |
| PAY.PHP
INDEX.PHP |
(after filling the form correctly
CAB is booked)
|
MAIN.PHP
|
LOGOUT BUTTON
|
INDEX.PHP
**THE MAIN FOLDER INCLUDES THE OTHER FILES TOO WHICH WORK IN THE BACK GROUND
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage{float}
\title{\Large{\textbf{ABHI CAB\\
Software Lab Report\\
CS699}\\
Indian Institute of Technology, Bombay}}
\newline
\newline
\author{Krushna Abhijit Patil \\
M.Tech.(I)\\
193059005}
\date{27 November 2019}
\begin{document}
\maketitle
\thispagestyle{empty}
\newpage
\tableofcontents
\thispagestyle{empty}
\newpage
\setcounter{page}{1}
\pagenumbering{arabic}
\section{Introduction}
Abhi Cab is a wide platform for drivers and customers to ease travelling. Anyone can register their car and anyone can book rides through website. The booking process is transparent, intuitive and streamlined. There are no hidden costs or fineprint. Hire a taxi for a round trip or avail one-way cab service on select routes. We strive to go that extra mile just to delight you, the customer, with our quality of service. From the booking to the driver to the cab, the experience is easy and seamless. When you book a car with us, you can be assured that our promise of quality is met.
\\
\\
\section{Motivation}
Cab service is a leading service running through various apps and websites. Cab scheduling, database handling can all be done in this service. A project which gives you an opportunity to handle various skills in one stream line. Our project includes implementation of the lessons learnt from software lab course. Our project tries to demonstrate use of maximum techniques to handle things right from database to aesthetics.
\newpage
\section{User Documentation}
Unlike other cab services, this website also gives you easy and great interface to drivers and customers.
\newline
\newline
As one opens the webpage he can have the overview how the website really works. It has four main tabs namely Home, Book Now, About us and Contact us. When you click on Book now first the website asks you to login. About us gives the overview of its developer. Contact us includes all the primary contact details like mobile number, Whatsapp and email id.
Below you can see two clickable command buttons namely Driver and Customer that direct you to different user pages.\\
\begin{figure}[h]
\centering
\includegraphics[scale=0.25]{1.jpeg}
\caption{Home page}
\end{figure}
\newpage
\subsection{\textbf{Driver}}
It has two sub options as Log in and Sign Up. When a person is using it for the first time has to sign up. There after he can login with his Username as Email id and Password.
\newline
\newline
Sign up page has following fields that driver has to enter the details compulsory:
Name with text entry, Mobile number with ten digit number entry, Gender with three radio buttons, Email id with text entry, License number with ten digit number entry, Car number with four digit number entry, Car image which one has to upload in pic format, New password and Confirm password to set password with asterisk signs on character entry.
You can check or uncheck remember me option.
You can submit or cancel this at anytime. If you miss any of the field it notifies you to fill the field.
\newline
\newline
When you click on submit it directs you to driver page where a driver can see his past rides, future rides and can also create a ride.
Create ride page has to bee filled with details such as pick up place, destination, fare, etc.\\
\\
\begin{figure}[h]
\centering
\includegraphics[scale=0.25]{2.jpeg}
\caption{Driver Sign up (1)}
\end{figure}
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{3.jpeg}
\caption{Driver Sign up (2)}
\end{figure}
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{4.jpeg}
\caption{Driver Sign up (3)}
\end{figure}
\newpage
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{5.jpeg}
\caption{Create Ride}
\end{figure}
\newpage
\subsection{\textbf{Customer}}
It has two sub options as Log in and Sign Up. When a person is using it for the first time has to sign up. There after he can login with his Username as Email id and Password.
\newline
\newline
Sign up page has following fields that driver has to enter the details compulsory:
Name with text entry, Mobile number with ten digit number entry, Gender with three radio buttons, Email id with text entry, New password and Confirm password to set password with asterisk signs on character entry.
You can check or uncheck remember me option.
You can submit or cancel this at anytime. If you miss any of the field it notifies you to fill the field.
\newline
\newline
When a customer has logged in he can schedule his ride with date, pickup location and destination.\\
\\
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{7.jpeg}
\caption{Customer Sign up (1)}
\end{figure}
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{8.jpeg}
\caption{Customer Sign up (2)}
\end{figure}
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{9.jpeg}
\caption{Booking Cab (1)}
\end{figure}
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{10.jpeg}
\caption{Booking Cab (2)}
\end{figure}
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{11.jpeg}
\caption{Booking Cab (3)}
\end{figure}
\newpage
\subsection{\textbf{About Us}}
This page gives overview on founder of the company explaining his dynamic nature and personality.\\
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{13.jpeg}
\caption{About Us}
\end{figure}
\newpage
\subsection{\textbf{Contact Us}}
This page gives all the contact details.
\\
\begin{figure}[htbp]
\centering
\includegraphics[scale=0.25]{14.jpeg}
\caption{Contact Us}
\end{figure}
\end{document}
<!DOCKTYPE html>
<html>
<head>
<title>About Us</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<style>
.footer {
color: white;
background-color: black;
margin-left: 0px;
text-align: center;
position:fixed;
bottom: 0;
height: 50px;
width: 100%;
}
.container {
width:100%;
padding: 16px;
margin-top:200px;
opacity: 0.7;
background-color:#ffffff;
}
</style>
<!--<script>
function login() {
alert("Please login to book your cab");
}
</script>-->
<body style="overflow-x:hidden;background-size:100% 100%;background-repeat: no-repeat;bottom: 0;background-attachment: fixed;" background="images/about_us.jpeg">
<div>
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation" style="padding: 0px margin:0px">
<div class="main" >
<div class="col-sm-6" >
<h1 align="left" style="margin-left:10px;" ><font color="white" size="15"> ABHI CAB</font>
<img src="images/logo.png" alt="google.com" width="100" height="50" align="left" style="margin-left:10px;">
</h1>
</div>
<div class="col-sm-6" style="margin-top:40px;">
<ul class="nav navbar-nav navbar-right" style="margin-right:10px;">
<li >
<a href="index.php"> Home <span class="glyphicon glyphicon-home"></span></a>
</li>
<!--<li onclick="login()"><a>Book Now <span class="glyphicon glyphicon-shopping-cart"></span></a></li>-->
<li class="active"><a href="about_us.php">About Us</a></li>
<li><a href="contact.php">Contact Us <span class="glyphicon glyphicon-earphone"></span></a></li>
<!--<li><a href="logout.php">Log Out <span class="glyphicon glyphicon-earphone"></span></a></li>-->
</ul>
</div>
</div>
</nav>
</div>
<div class="col-sm-1"></div>
<div class="col-sm-6">
<div class="container" >
<h1 >ABOUT US</h1>
<h3><p><b>Krushna Patil</b>, a dynamic personality of <b>Nashik</b> founded the ABHI CAB in 2019 with his great efforts
and perseverance. The unique name ABHI signifies his role model i.e., his <b>father Abhijit and ABHI in
our National language means immediately</b>. ABHI CAB integrates city transportation for
customers and driver-partners onto a mobile technology platform ensuring convenient,
transparent, and quick service fulfilment.</p>
<p>Though being new in the market, ABHI CAB is on the front to explore it’s immense potential in this
emerging market. Providing excellent services it is over the head lines of Nashik becoming favourite
service provider for citizens.</p>
<p>Using new emerging technologies, offering high quality interactive and productive services to
customers ABHI CAB will soon expand in many cities.</p></h3>
</div>
<div class="col-sm-5"></div>
</div>
<!-- Footer -->
<footer class="footer">
<h5>Copyright &copy; 2019 AbhiCab.com</h5>
</footer>
</div>
</body>
</html>
<?php
session_start();
require('connect.php');
//echo '<script>alert("BEFORE BUTTEN PRESS");</script>';
?>
<!DOCKTYPE html>
<html>
<head>
<title>Admin</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<style>
.footer {
color: white;
background-color: black;
margin-left: 0px;
text-align: center;
position:fixed;
bottom: 0;
height: 50px;
width: 100%;
}
.container {
width:100%;
padding: 16px;
margin-top:30px;
margin-bottom:60px;
opacity:0.5;
background-color:#ffffff;
}
.container1 {
width:100%;
padding: 16px;
margin-top:50px;
margin-bottom:60px;
opacity:0.5;
background-color:#ffffff;
}
</style>
<body style="overflow-x:hidden;background-size:100% 100%;background-repeat: no-repeat;bottom: 0;background-attachment: fixed;" background="images/admin.jpg">
<div>
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation" style="padding: 0px margin:0px">
<div class="main" >
<div class="col-sm-6" >
<h1 align="left" style="margin-left:10px;" ><font color="white" size="15"> ABHI CAB</font>
<img src="images/logo.png" alt="google.com" width="100" height="50" align="left" style="margin-left:10px;">
</h1>
</div>
<div class="col-sm-6" style="margin-top:40px;">
<ul class="nav navbar-nav navbar-right" style="margin-right:10px;">
<li >
<a href="index.php"> Home <span class="glyphicon glyphicon-home"></span></a>
</li>
<li><a href="main.php">Book Now <span class="glyphicon glyphicon-shopping-cart"></span></a></li>
<li ><a href="about_us.html">About Us</a></li>
<li><a href="contact.html">Contact Us <span class="glyphicon glyphicon-earphone"></span></a></li>
<li><a href="logout.php">Log Out <span class="glyphicon glyphicon-earphone"></span></a></li>
</ul>
</div>
</div>
</nav>
</div>
<h2 style="margin-top:150px" align="center"><font size="8" color="BLACK" ><b>ADMIN</b></font></h2>
<div class="col-sm-1"></div>
<div class="col-sm-4">
<div class="container">
<h3 align="center"><b>HISTORY</b></h3>
<?php
//echo '<script>alert("BEFORE BUTTEN PRESS");</script>';
$sql = "SELECT * FROM CUSTDRIV WHERE DATEOFTRAVEL < (SELECT CURDATE())";
if($result = mysqli_query($con, $sql))
{
if(mysqli_num_rows($result) > 0)
{
echo '<table style="width:100%; "><font text-color="white">';
echo '<tr>';
echo '<th>Cust ID</th>';
echo '<th>Cust Name</th>';
echo '<th>Driver ID</th>';
echo '<th>Driver Name</th>';
echo '<th>Process ID</th>';
echo '</tr>';
echo '<tbody>';
while($row = mysqli_fetch_array($result))
{
$cid=$row['CID'];
$did=$row['DID'];
$pid=$row['PROCESSID'];
$sql1 = "SELECT * FROM customer where cid=$cid";
if($result1 = mysqli_query($con, $sql1))
{
if(mysqli_num_rows($result1) > 0)
{
$row1 = mysqli_fetch_array($result1);
$cname=$row1['CNAME'];
}
mysqli_free_result($result1);
}
$sql1 = "SELECT * FROM driver where did=$did";
if($result1 = mysqli_query($con, $sql1))
{
if(mysqli_num_rows($result1) > 0)
{
$row1 = mysqli_fetch_array($result1);
$dname=$row1['DNAME'];
}
mysqli_free_result($result1);
}
//<!--Use a while loop to make a table row for every DB row-->
echo '<tr>';
//<!--Each table column is echoed in to a td cell-->
echo '<td>';
echo $cid;
echo '</td>';
echo '<td>';
echo $cname;
echo '</td>';
echo '<td>';
echo $did;
echo '</td>';
echo '<td>';
echo $dname;
echo '</td>';
echo '<td>';
echo $pid;
echo '</td>';
echo '</tr>';
}
}
echo '</tbody>';
}
?>
<table style="width:100%; "><font text-color="white">
</font></table>
</div>
</div>
<div class="row">
<div class="col-sm-2"></div>
<div class="col-sm-4">
<div class="container">
<h3 align="center"><b>FUTURE</b></h3>
<?php
//echo '<script>alert("BEFORE BUTTEN PRESS");</script>';
$sql = "SELECT * FROM CUSTDRIV WHERE DATEOFTRAVEL > (SELECT CURDATE())";
if($result = mysqli_query($con, $sql))
{
if(mysqli_num_rows($result) > 0)
{
echo '<table style="width:100%; "><font text-color="white">';
echo '<tr>';
echo '<th>Cust ID</th>';
echo '<th>Cust Name</th>';
echo '<th>Driver ID</th>';
echo '<th>Driver Name</th>';
echo '<th>Process ID</th>';
echo '</tr>';
echo '<tbody>';
while($row = mysqli_fetch_array($result))
{
$cid=$row['CID'];
$did=$row['DID'];
$pid=$row['PROCESSID'];
$sql1 = "SELECT * FROM customer where cid=$cid";
if($result1 = mysqli_query($con, $sql1))
{
if(mysqli_num_rows($result1) > 0)
{
$row1 = mysqli_fetch_array($result1);
$cname=$row1['CNAME'];
}
mysqli_free_result($result1);
}
$sql1 = "SELECT * FROM driver where did=$did";
if($result1 = mysqli_query($con, $sql1))
{
if(mysqli_num_rows($result1) > 0)
{
$row1 = mysqli_fetch_array($result1);
$dname=$row1['DNAME'];
}
mysqli_free_result($result1);
}
//<!--Use a while loop to make a table row for every DB row-->
echo '<tr>';
//<!--Each table column is echoed in to a td cell-->
echo '<td>';
echo $cid;
echo '</td>';
echo '<td>';
echo $cname;
echo '</td>';
echo '<td>';
echo $did;
echo '</td>';
echo '<td>';
echo $dname;
echo '</td>';
echo '<td>';
echo $pid;
echo '</td>';
echo '</tr>';
}
}
echo '</tbody>';
}
?>
<table style="width:100%; "><font text-color="white">
</font></table>
</div>
</div>
<div class="col-sm-1"></div>
</div>
<div class="col-sm-4"></div>
<div class="col-sm-4">
<div class="container1">
<h3 align="center"><b>ON GOING</b></h3>
<?php
//echo '<script>alert("BEFORE BUTTEN PRESS");</script>';
$sql = "SELECT * FROM CUSTDRIV WHERE DATEOFTRAVEL = (SELECT CURDATE())";
if($result = mysqli_query($con, $sql))
{
if(mysqli_num_rows($result) > 0)
{
echo '<table style="width:100%; "><font text-color="white">';
echo '<tr>';
echo '<th>Cust ID</th>';
echo '<th>Cust Name</th>';
echo '<th>Driver ID</th>';
echo '<th>Driver Name</th>';
echo '<th>Process ID</th>';
echo '</tr>';
echo '<tbody>';
while($row = mysqli_fetch_array($result))
{
$cid=$row['CID'];
$did=$row['DID'];
$pid=$row['PROCESSID'];
$sql1 = "SELECT * FROM customer where cid=$cid";
if($result1 = mysqli_query($con, $sql1))
{
if(mysqli_num_rows($result1) > 0)
{
$row1 = mysqli_fetch_array($result1);
$cname=$row1['CNAME'];
}
mysqli_free_result($result1);
}
$sql1 = "SELECT * FROM driver where did=$did";
if($result1 = mysqli_query($con, $sql1))
{
if(mysqli_num_rows($result1) > 0)
{
$row1 = mysqli_fetch_array($result1);
$dname=$row1['DNAME'];
}
mysqli_free_result($result1);
}
//<!--Use a while loop to make a table row for every DB row-->
echo '<tr>';
//<!--Each table column is echoed in to a td cell-->
echo '<td>';
echo $cid;
echo '</td>';
echo '<td>';
echo $cname;
echo '</td>';
echo '<td>';
echo $did;
echo '</td>';
echo '<td>';
echo $dname;
echo '</td>';
echo '<td>';
echo $pid;
echo '</td>';
echo '</tr>';
}
}
echo '</tbody>';
}
?>
<table style="width:100%; "><font text-color="white">
</font></table>
</div>
</div>
<div class="col-sm-4"></div>
<!-- Footer -->
<footer class="footer">
<h5>Copyright &copy; 2018 AbhiCab.com</h5>
</footer>
</div>
</body>
</html>
<!DOCTYPE HTML>
<HTML lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title></title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<div class="container">
<button class="btn btn1"> hello </button>
<button class="btn btn2"> hello </button>
<button class="btn btn3"> hello </button>
<button class="btn btn4"> hello </button>
</div>
</body>
</HTML>
\ No newline at end of file
<?php
//Set Variables
// this is a file use to connect to the database
// it consist of the host name database name(that is create on phpmyadmin) usernmae at phpmyadmin
// and the password for the username
// password can be left empty if u have no password for the username
$host="localhost";
$db="Abhi_Cab";
$username="root";
$pass="Aaiproud!1";
$con=new mysqli($host,$username,$pass,$db);
?>
<!DOCKTYPE html>
<html>
<head>
<title>Contact Us</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<style>
.footer {
color: white;
background-color: black;
margin-left: 0px;
text-align: center;
position:fixed;
bottom: 0;
height: 50px;
width: 100%;
}
.container {
width:100%;
padding: 16px;
margin-top:200px;
opacity: 0.5;
background-color:#ffffff;
}
.container1 {
width:100%;
padding: 1px;
margin-top:100px;
background-color:#ffffff;
}
.container2 {
width:100%;
padding: 1px;
margin-top:20px;
background-color:#ffffff;
}
</style>
<!--<script>
function login() {
alert("Please login to book your cab");
}
</script>-->
<body style="overflow-x:hidden;background-size:100% 100%;background-repeat: no-repeat;bottom: 0;background-attachment: fixed;" background="images/contact.jpg">
<div>
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation" style="padding: 0px margin:0px">
<div class="main" >
<div class="col-sm-6" >
<h1 align="left" style="margin-left:10px;" ><font color="white" size="15"> ABHI CAB</font>
<img src="images/logo.png" alt="google.com" width="100" height="50" align="left" style="margin-left:10px;">
</h1>
</div>
<div class="col-sm-6" style="margin-top:40px;">
<ul class="nav navbar-nav navbar-right" style="margin-right:10px;">
<li >
<a href="index.php"> Home <span class="glyphicon glyphicon-home"></span></a>
</li>
<!--<li onclick="login()"><a>Book Now <span class="glyphicon glyphicon-shopping-cart"></span></a></li>-->
<li><a href="about_us.php">About Us</a></li>
<li class="active"><a href="contact.php">Contact Us <span class="glyphicon glyphicon-earphone"></span></a></li>
<!--<li><a href="logout.php">Log Out <span class="glyphicon glyphicon-earphone"></span></a></li>-->
</ul>
</div>
</div>
</nav>
</div>
<div class="col-sm-7"></div>
<div class="col-sm-4">
<div class="container" id="contact">
<h2 align="center">CONTACT US</h2>
<hr>
<div class="col-sm-5">
<img src="images/whatsapp.jpeg" width="30%" style="margin-left:85px">
</div>
<div class="col-sm-7">
<p><font text-align="center" size="4">9405183208</font></p>
</div>
<div class="container1">
<p align="center"><font size="4">Call Us @ 8208381441</font></p>
</div>
<div class="container2">
<p align="center"><font size="4">Mail @ krushnap@cse.iitb.ac.in</font></p>
</div>
</div>
</div>
<div class="col-sm-1"></div>
<!-- Footer -->
<footer class="footer">
<h5>Copyright &copy; 2019 AbhiCab.com</h5>
</footer>
</div>
</body>
</html>
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
.USER {
background: #124680;
min-height: 400px;
color: #fff;
padding: 40px 0 0;
position: relative;
margin-top: 130px;
background-image: url("images/car.jpg");
background-repeat: no-repeat;
background-size: 100% 100%;
background-color: #cccccc;
}
<?php
session_start();
require('connect.php');
require('functions.php');
//echo '<script>alert("before clicking the button");</script>';
if(isset($_REQUEST['customer_subt_btn'])){
//echo '<script>alert("after clicking the button");</script>';
echo $_POST['customer_name'];
$name=$_POST['customer_name'];
$email=$_POST['customer_email'];
$email=test_input($email);
$password=$_POST['customer_password'];
$password=test_input($password);
$passwordConfirm=$_POST['customer_confirmpawword'];
$passwordConfirm=test_input($passwordConfirm);
$mobile=$_POST['customer_mobile'];
$mobile=test_input($mobile);
if($email=="" || substr($email, -10)!="@gmail.com" || $password=="" || $passwordConfirm=="" || $password!=$passwordConfirm || $name=="")
{
echo '<script>alert("Enter Email id assigned by college");</script>';
}
else
{
$checkcustomerQuery="SELECT cemail FROM customer WHERE cemail='$email'";
$checkcustomerQuery=mysqli_query($con,$checkcustomerQuery);
if(mysqli_num_rows($checkcustomerQuery) > 0)
{// customer user exists
echo '<script>alert("User with this mail already exist");</script>';
}
else
{//customer does not exist
$insertcustomer="INSERT INTO customer (CNAME, CMOBILE, CEMAIL, CPASSWORD, CID) VALUES ('$name', '$mobile', '$email', '$password', NULL)";
if(mysqli_query($con,$insertcustomer))
{
//user added
//echo '<script> alert("Registration successful"); </script>';
$_SESSION['id']=$email;
$_SESSION['type']="student";
header('Refresh:0 url=main.php');
}
else
{
echo '<script> alert("Cannot add user"); </script>';
}
}
}
}
?>
<!DOCKTYPE html>
<html>
<head>
<title>Sign Up</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script>
function customer_submit_btn_onclick(){
localStorage.setItem("user_type", "customer");
var enteredEmail=document.getElementById("cemail").value;
var enteredPassword=document.getElementById("cpassword").value;
var enteredConfirmPassword=document.getElementById("cpasswordconfirm").value;
var enteredName=document.getElementById("cname").value;
var enteredmobile=document.getElementById("cmobile").value;
alert(enteredmobile);
if(enteredPassword=="" || enteredEmail=="" || enteredConfirmPassword=="" || enteredName==""){
alert("Enter all fields");
}
else{
//check for @gmail.com
if(enteredEmail.substr(enteredEmail.length - 10)=="@gmail.com"){
if(enteredPassword==enteredConfirmPassword){
}
else{
alert("Passwords do not match");
}
}
else{
alert("Please use email provided by gmail ");
}
}
}
</script>
<style>
form {
border: 3px solid #f1f1f1;
}
input[type=text], input[type=password] {
width: 100%;
padding: 12px 20px;
margin: 8px 0;
display: inline-block;
border: 1px solid #ccc;
box-sizing: border-box;
}
button {
background-color: #4CAF50;
color: white;
padding: 14px 20px;
margin: 8px 0;
border: none;
cursor: pointer;
width: 100%;
}
button:hover {
opacity: 5.0;
}
.cancelbtn {
width:100%
padding: 10px 18px;
background-color: #f44336;
}
.imgcontainer {
text-align: center;
margin: 24px 0 12px 0;
}
img.avatar {
width: 40%;
border-radius: 50%;
}
.container {
width:100%;
padding: 16px;
}
span.psw {
float: right;
padding-top: 16px;
}
.footer {
color: white;
background-color: black;
margin-left: 0px;
text-align: center;
position:fixed;
bottom: 0;
height: 50px;
width: 100%;
}
/* Change styles for span and cancel button on extra small screens */
@media screen and (max-width: 300px) {
span.psw {
display: block;
float: none;
}
.cancelbtn {
width: 70%;
}
}
</style>
</head>
<body style="overflow-x:hidden;background-size:100% 100%;background-repeat: no-repeat;bottom: 0;background-attachment: fixed;" background="images/blogin.jpg">
<div>
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation" style="padding: 0px margin:0px">
<div class="main" >
<div class="col-sm-6" >
<h1 align="left" style="margin-left:10px;" ><font color="white" size="15"> ABHI CAB</font>
<img src="images/logo.png" alt="google.com" width="100" height="50" align="left" style="margin-left:10px;">
</h1>
</div>
<div class="col-sm-6" style="margin-top:40px;">
<ul class="nav navbar-nav navbar-right" style="margin-right:10px;">
<li >
<a href="index.php"> Home <span class="glyphicon glyphicon-home"></span></a>
</li>
<li class="active" ><a class="dropdown-toggle" data-toggle="dropdown" href="#">Login <span class="caret"></span></a>
<ul class="dropdown-menu" >
<li align="right"><a href="index.php">Customer <span class="glyphicon glyphicon-user"></span></a></li>
<li align="right"><a href="index.php">Admin <span class="glyphicon glyphicon-user"></span></a></li>
<li align="right"><a href="index.php">Driver <span class="glyphicon glyphicon-user"></span></a></li>
</ul>
</li>
<li><a href="main.php">Book Now <span class="glyphicon glyphicon-shopping-cart"></span></a></li>
<li><a href="about_us.html">About Us</a></li>
<li><a href="contact.html">Contact Us <span class="glyphicon glyphicon-earphone"></span></a></li>
</ul>
</div>
</div>
</nav>
</div>
<div class="col-sm-2"></div>
<div class="col-sm-8">
<form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" style="margin-top:100px; margin-bottom:100px" method="post">
<div class="imgcontainer">
<img src="images/login.png" alt="Avatar" class="avatar">
</div>
<div class="container">
<h2 align="center"><font color="red"><b>CUSTOMER SIGN UP</b></font></h2>
<label><b><font color="white" size="4">Name</font></b></label>
<input type="text" placeholder="Enter Name" name="customer_name" id="cname" required>
<hr>
<label><b><font color="white" size="4">Mobile Number</font></b></label>
<input type="text" placeholder="Enter Mobile NUmber" name="customer_mobile" id="cmobile" required>
<hr>
<label><b><font color="white" size="4">Gender</font></b></label>
<br></br>
<input type="radio" > <font color="white" size="4">Male</font>
<input type="radio" > <font color="white" size="4">Female</font>
<input type="radio" > <font color="white" size="4">Other</font>
<hr>
<label><b><font color="white" size="4">Email</font></b></label>
<input type="text" placeholder="Enter Email" name="customer_email" id="cemail" required>
<hr>
<label><b><font color="white" size="4">New Password</font></b></label>
<input type="password" placeholder="Enter Password" name="customer_password" id="cpassword" required>
<hr>
<label><b><font color="white" size="4">Confirm Password</font></b></label>
<input type="password" placeholder="Enter same Password" name="customer_confirmpawword" id="cpasswordconfirm" required>
<label>
<input type="checkbox" checked="checked"> <font color="white" size="4">Remember me</font>
</label>
</div>
<div class="col-sm-6">
<button type="submit" name="customer_subt_btn" onClick="customer_submit_btn_onclick()">Submit</button>
</div>
<div class="col-sm-6">
<a href="index.php"><button type="button" class="cancelbtn">Cancel</button></a>
</div>
</form>
<div class="copy-right" style="padding:0px; bottom:true;">
<p align="center">&copy; 2018 AbhiCab.com</p>
</div>
</div>
<div class="col-sm-2" ></div>
<!-- Footer -->
<footer class="footer">
<h5>Copyright &copy; 2019 AbhiCab.com</h5>
</footer>
</body>
</php>
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
<script type="text/javascript">
var origin = new google.maps.LatLng(55.930385, -3.118425),
destination = "Stockholm, Sweden",
service = new google.maps.DistanceMatrixService();
service.getDistanceMatrix(
{
origins: [origin],
destinations: [destination],
travelMode: google.maps.TravelMode.DRIVING,
avoidHighways: false,
avoidTolls: false
},
callback
);
function callback(response, status) {
var orig = document.getElementById("orig"),
dest = document.getElementById("dest"),
dist = document.getElementById("dist");
if(status=="OK") {
orig.value = response.destinationAddresses[0];
dest.value = response.originAddresses[0];
dist.value = response.rows[0].elements[0].distance.text;
} else {
alert("Error: " + status);
}
}
</script>
</head>
<body>
<br>
Basic example for using the Distance Matrix.<br><br>
Origin: <input id="orig" type="text" style="width:35em"><br><br>
Destination: <input id="dest" type="text" style="width:35em"><br><br>
Distance: <input id="dist" type="text" style="width:35em">
<a href='http://www.mcgm.gov.in/' target='_blank'>Mumbai</a>
</body>
</html>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
<!DOCTYPE html>
<html>
<body>
<form action="upload.php" method="post" enctype="multipart/form-data">
Select image to upload:
<input type="file" name="fileToUpload" id="fileToUpload" accept="image/*">
<input type="submit" value="Upload Image" name="submit">
</form>
</body>
</html>
This source diff could not be displayed because it is too large. You can view the blob instead.
<?php
function loggedin(){
if((isset($_SESSION['id']) && $_SESSION['id']!=null) && (isset($_SESSION['type']) && $_SESSION['type']!=null)){
return true;
}
return false;
}
function test_input($data) {
$data = trim($data);
$data = stripslashes($data);
$data = htmlspecialchars($data);
return $data;
}
?>
\ No newline at end of file
window.alert("hello ur in js file");
var abc = document.getElementById('swift').style.display="none";
win
if(abc > 0)
window.alert("found swift");
else
window.alert("not found");
<form action="saveimage.php" enctype="multipart/form-data" method="post">
<table style="border-collapse: collapse; font: 12px Tahoma;" border="1" cellspacing="5" cellpadding="5">
<tbody><tr>
<td>
<input name="uploadedimage" type="file">
</td>
</tr>
<tr>
<td>
<input name="Upload Now" type="submit" value="Upload Image">
</td>
</tr>
</tbody></table>
</form>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
// This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment.
require('../../js/transition.js')
require('../../js/alert.js')
require('../../js/button.js')
require('../../js/carousel.js')
require('../../js/collapse.js')
require('../../js/dropdown.js')
require('../../js/modal.js')
require('../../js/tooltip.js')
require('../../js/popover.js')
require('../../js/scrollspy.js')
require('../../js/tab.js')
require('../../js/affix.js')
\ No newline at end of file
<?php
// Start the session
session_start();
?>
<!DOCTYPE html>
<html>
<head>
<script>
var a="Hello";
</script>
</head>
<body>
<script>
var queryString = decodeURIComponent(window.location.search);
queryString = queryString.substring(1);
var queries = queryString.split("&");
for (var i = 0; i < queries.length; i++)
{
document.write(queries[i] + "<br>");
}
</script>
<?php
echo $variable = "<script>document.write(a)</script>"; //I want above javascript variable 'a' value to be store here
?>
<?php
// Set session variables
$did=$_SESSION["favcolor"];
echo '<script type=\'text/javascript\'>';
echo 'alert("driver id is'.$did.'");';
echo '</script>';
$_SESSION["favanimal"] = "cat";
echo "Session variables are set.";
?>
<?php
echo "<h1>Screen Resolution:</h1>";
echo "Width : ".$_GET['vee']."<br>";
?>
</body>
</html>
<?php
session_start();
require('connect.php');
require('functions.php');
$r="SELECT * FROM logs ";
//$id="SELECT did FROM driver WHERE demail='".$username."' and dpassword='".$password."'";
$abc=mysqli_query($con,$r);
if(mysqli_num_rows($abc) > 0)
{
//echo '<script>alert("hello driver make ur cab ready");</script>';
while($row = mysqli_fetch_array($abc))
{
$did=$row['LID'];
if(isset($_POST[$did]))
{
$rate=$_POST['rate'];
$rate=test_input($rate);
$_SESSION["rate"] = $rate;
$_SESSION["favcolor"] = $did;
header('Refresh:0 url=pay.php');
//echo '<a href='krushna.php'></a>';
}
}
}
?>
\ No newline at end of file
<?php
session_start();
session_destroy();
unset($_SESSION['id']);
unset($_SESSION['type']);
header('Refresh:3 url=index.php');
//echo "<br><br> LOGGING YOU OUT...!!!";
?>
<!DOCKTYPE html>
<html>
<head>
<title>Abhi Cab</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
</head>
<style type="text/css">
.footer {
color: white;
background-color: black;
margin-left: 0px;
text-align: center;
position:fixed;
bottom: 0;
height: 8%;
width: 100%;
}
</style>
<body style="overflow-x:hidden;background-size:100% 100%;background-repeat: no-repeat;bottom: 0;background-attachment: fixed;" background="images/logout2.gif" >
<footer class="footer">
<h5>Copyright &copy; 2019 AbhiCab.com</h5>
</footer>
</body>
</html>
\ No newline at end of file
This diff is collapsed.
<?php
session_start();
require('connect.php');
require('functions.php');
echo '<script>alert("before clicking the button");</script>';
if(isset($_REQUEST['customer_subt_btn'])){
echo '<script>alert("after clicking the button");</script>';
echo '<script type=\'text/javascript\'>';
echo 'alert("hello'.$_POST['customer_name'].'");';
echo '</script>';
//echo $_POST['customer_name'];
}
?>
<!DOCKTYPE html>
<html>
<head>
<title>Sign Up</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script>
function customer_submit_btn_onclick(){
localStorage.setItem("user_type", "customer");
var enteredEmail=document.getElementById("cemail").value;
var enteredPassword=document.getElementById("cpassword").value;
var enteredConfirmPassword=document.getElementById("cpasswordconfirm").value;
var enteredName=document.getElementById("cname").value;
var enteredmobile=document.getElementById("cmobile").value;
alert(enteredmobile);
if(enteredPassword=="" || enteredEmail=="" || enteredConfirmPassword=="" || enteredName==""){
alert("Enter all fields");
}
else{
//check for @gmail.com
if(enteredEmail.substr(enteredEmail.length - 10)=="@gmail.com"){
if(enteredPassword==enteredConfirmPassword){
}
else{
alert("Passwords do not match");
}
}
else{
alert("Please use email provided by vit.edu");
}
}
}
</script>
<style>
form {
border: 3px solid #f1f1f1;
}
input[type=text], input[type=password] {
width: 100%;
padding: 12px 20px;
margin: 8px 0;
display: inline-block;
border: 1px solid #ccc;
box-sizing: border-box;
}
button {
background-color: #4CAF50;
color: white;
padding: 14px 20px;
margin: 8px 0;
border: none;
cursor: pointer;
width: 100%;
}
button:hover {
opacity: 5.0;
}
.cancelbtn {
width:100%
padding: 10px 18px;
background-color: #f44336;
}
.imgcontainer {
text-align: center;
margin: 24px 0 12px 0;
}
img.avatar {
width: 40%;
border-radius: 50%;
}
.container {
width:100%;
padding: 16px;
}
span.psw {
float: right;
padding-top: 16px;
}
.footer {
color: white;
background-color: black;
margin-left: 0px;
text-align: center;
position:fixed;
bottom: 0;
height: 50px;
width: 100%;
}
/* Change styles for span and cancel button on extra small screens */
@media screen and (max-width: 300px) {
span.psw {
display: block;
float: none;
}
.cancelbtn {
width: 70%;
}
}
</style>
</head>
<body style="overflow-x:hidden;background-size:100% 100%;background-repeat: no-repeat;bottom: 0;background-attachment: fixed;" background="images/blogin.jpg">
<div>
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation" style="padding: 0px margin:0px">
<div class="main" >
<div class="col-sm-6" >
<h1 align="left" style="margin-left:10px;" ><font color="white" size="15"> ABHI CAB</font>
<img src="images/logo.png" alt="google.com" width="100" height="50" align="left" style="margin-left:10px;">
</h1>
</div>
<div class="col-sm-6" style="margin-top:40px;">
<ul class="nav navbar-nav navbar-right" style="margin-right:10px;">
<li >
<a href="index.html"> Home <span class="glyphicon glyphicon-home"></span></a>
</li>
<li class="active" ><a class="dropdown-toggle" data-toggle="dropdown" href="#">Login <span class="caret"></span></a>
<ul class="dropdown-menu" >
<li align="right"><a href="index.html">Customer <span class="glyphicon glyphicon-user"></span></a></li>
<li align="right"><a href="index.html">Admin <span class="glyphicon glyphicon-user"></span></a></li>
<li align="right"><a href="index.html">Driver <span class="glyphicon glyphicon-user"></span></a></li>
</ul>
</li>
<li><a href="main.html">Book Now <span class="glyphicon glyphicon-shopping-cart"></span></a></li>
<li><a href="about_us">About Us</a></li>
<li><a href="contact.html">Contact Us <span class="glyphicon glyphicon-earphone"></span></a></li>
</ul>
</div>
</div>
</nav>
</div>
<div class="col-sm-2"></div>
<div class="col-sm-8">
<form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>" style="margin-top:100px; margin-bottom:100px" method="post">
<div class="imgcontainer">
<img src="images/login.png" alt="Avatar" class="avatar">
</div>
<div class="container">
<h2 align="center"><font color="red"><b>CUSTOMER SIGN UP</b></font></h2>
<label><b><font color="white" size="4">Name</font></b></label>
<input type="text" placeholder="Enter Name" name="customer_name" id="cname" required>
<hr>
<div class="col-sm-6">
<button type="submit" name="customer_subt_btn" onClick="customer_submit_btn_onclick()">Submit</button>
</div>
<div class="col-sm-6">
<a href="index.html"><button type="button" class="cancelbtn">Cancel</button></a>
</div>
</div>
</form>
<div class="copy-right" style="padding:0px; bottom:true;">
<p align="center">&copy; 2018 AbhiCab.com</p>
</div>
<div class="col-sm-2" ></div>
<!-- Footer -->
<footer class="footer">
<h5>Copyright &copy; 2018 AbhiCab.com</h5>
</footer>
</body>
</html>
var saveBtn=document.getElementById("saveProfileBtn");
var editBtn=document.getElementById("editProfileBtn");
// Edit and save buttons
editBtn.style.display="none";
saveBtn.style.display="block";
<!--<!DOCTYPE html>
<html>
<script>
var news_all_file = "https://www.distance24.org/route.json?stops=mumbai|pune";
$.get(news_all_file, {
}, function(data) {
//j = $.parseJSON(data);
for (k in data) {
var x = data[k];
alert(x);
}
</script>
</html>-->
<!--
<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
$("button").click(function(){
$.getJSON("https://www.distance24.org/route.json?stops=mumbai|pune", function(result){
for (k in result){
$("div").append(k + " ");
}
});
});
});
</script>
</head>
<body>
<button>Get JSON data</button>
<div></div>
</body>
</html>
-->
<?php
//units=For temperature in Celsius use units=metric
//5128638 is new york ID
$url = "https://www.distance24.org/route.json?stops=mumbai|pune";
$contents = file_get_contents($url);
$clima=json_decode($contents);
$temp_max=$clima->distance;
echo "string". $temp_max.".";
?>
\ No newline at end of file
var http = require('http');
var formidable = require('formidable');
var fs = require('fs');
http.createServer(function (req, res) {
if (req.url == '/fileupload') {
var form = new formidable.IncomingForm();
form.parse(req, function (err, fields, files) {
var oldpath = files.filetoupload.path;
var newpath = 'C:/Users/Your Name/' + files.filetoupload.name;
fs.rename(oldpath, newpath, function (err) {
if (err) throw err;
res.write('File uploaded and moved!');
res.end();
});
});
} else {
res.writeHead(200, {'Content-Type': 'text/html'});
res.write('<form action="fileupload" method="post" enctype="multipart/form-data">');
res.write('<input type="file" name="filetoupload"><br>');
res.write('<input type="submit">');
res.write('</form>');
return res.end();
}
}).listen(8080);
\ No newline at end of file
<!DOCTYPE html>
<html>
<head>
<title>How to Implement OTP SMS Mobile Verification in PHP with TextLocal</title>
<link href="style.css" type="text/css" rel="stylesheet" />
</head>
<body>
<div class="container">
<div class="error"></div>
<form id="frm-mobile-verification">
<div class="form-heading">Mobile Number Verification</div>
<div class="form-row">
<input type="number" id="mobile" class="form-input"
placeholder="Enter the 10 digit mobile">
</div>
<input type="button" class="btnSubmit" value="Send OTP"
onClick="sendOTP();">
</form>
</div>
<script src="jquery-3.2.1.min.js" type="text/javascript"></script>
<script src="verification.js"></script>
</body>
</html>
\ No newline at end of file
This diff is collapsed.
<?php
echo "<br><br> Wait......
<br>
<br> Transaction under process...!!!";
header('Refresh:3 url=t.php');
?>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<?php
$target_dir = "../uploads/";
$destination_path = getcwd().DIRECTORY_SEPARATOR;
$target_file = $destination_path . 'driver_images/'.($_FILES["fileToUpload"]["name"]);
//$target_file = $target_dir . basename($_FILES["fileToUpload"]["name"]);
$uploadOk = 1;
$imageFileType = strtolower(pathinfo($target_file,PATHINFO_EXTENSION));
// Check if image file is a actual image or fake image
if(isset($_POST["submit"])) {
$check = getimagesize($_FILES["fileToUpload"]["tmp_name"]);
if($check !== false) {
echo "File is an image - " . $check["mime"] . ".";
$uploadOk = 1;
} else {
echo "File is not an image.";
$uploadOk = 0;
}
}
//<?php
if (is_dir($tmp_name = $_FILES['fileToUpload']['tmp_name'])) {
echo 'the temporary folder exists<br>';
} else {
echo "the temp folder doesnt exist<br>" . $_FILES["fileToUpload"]["tmp_name"] . "<br>";
}
// Check if file already exists
if (file_exists($target_file)) {
echo "Sorry, file already exists.";
$uploadOk = 0;
}
// Check file size
if ($_FILES["fileToUpload"]["size"] > 500000) {
echo "Sorry, your file is too large.";
$uploadOk = 0;
}
// Allow certain file formats
if($imageFileType != "jpg" && $imageFileType != "png" && $imageFileType != "jpeg"
&& $imageFileType != "gif" ) {
echo "Sorry, only JPG, JPEG, PNG & GIF files are allowed.";
$uploadOk = 0;
}
// Check if $uploadOk is set to 0 by an error
if ($uploadOk == 0) {
echo "Sorry, your file was not uploaded.";
// if everything is ok, try to upload file
} else {
if (move_uploaded_file($_FILES['fileToUpload']['tmp_name'], "/uploads/")) {
echo "The file ". basename( $_FILES["fileToUpload"]["name"]). " has been uploaded.";
} else {
echo "my na ". ( $_FILES["fileToUpload"]["name"]). "jhvgdfjgjsd";
echo "Sorry, there was an error uploading your file.";
}
}
?>
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 to comment