|
1Server IP : 2a02:4780:11:1776:0:2637:29db:10 / Your IP : 216.73.216.15 Web Server : LiteSpeed System : Linux in-mum-web1676.main-hosting.eu 5.14.0-503.38.1.el9_5.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Apr 18 08:52:10 EDT 2025 x86_64 User : u641149403 ( 641149403) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : OFF | Python : OFF Directory (0755) : /home/u641149403/domains/mistytourandtravel.in/../theurbancabs.in/public_html/ |
| [ Home ] | [ C0mmand ] | [ Upload File ] |
|---|
<?php
include('smtp/PHPMailerAutoload.php');
//--------------- Quick Query -------------------
if (isset($_POST['pick'])) {
$name = $_POST['name'];
$phone = $_POST['phone'];
$pick = $_POST['pick'];
$drop = $_POST['drop'];
$date = $_POST['date'];
$time = $_POST['time'];
$html = '<html>
<head>
<title>Booking Details</title>
</head>
<body>
<table>
<style>
table{
width: 100%;
margin-bottom: 1rem;
color: #212529;
border-collapse: collapse;
}
table td, table th {
padding: 0.75rem;
vertical-align: top;
border-top: 1px solid #dee2e6;
}
</style>
<tr>
<td><b>Name - </b></td>
<td>' . $name . '</td>
</tr>
<tr>
<td><b>Phone Number - </b></td>
<td>' . $phone . '</td>
</tr>
<tr>
<td><b>Pickup Location - </b></td>
<td>' . $pick . '</td>
</tr>
<tr>
<td><b>Drop Location - </b></td>
<td>' . $drop . '</td>
</tr>
<tr>
<td><b>Pickup Date - </b></td>
<td>' . $date . '</td>
</tr>
<tr>
<td><b>Pickup Time - </b></td>
<td>' . $time . '</td>
</tr>
</table>
</body>
</html>';
}
if(isset($_POST['message_me'])) {
$fname = $_POST['fname'];
$lname = $_POST['lname'];
$email = $_POST['email'];
$phone = $_POST['phone'];
$message = $_POST['message_me'];
$html = '<html>
<head>
<title>Booking Details</title>
<style>
table {
width: 100%;
margin-bottom: 1rem;
color: #212529;
border-collapse: collapse;
}
table td, table th {
padding: 0.75rem;
vertical-align: top;
border-top: 1px solid #dee2e6;
}
</style>
</head>
<table>
<tr>
<td><b>Name - </b></td>
<td>' . $fname .' '.$lname . '</td>
</tr>
<tr>
<td><b>Phone Number - </b></td>
<td>' . $phone . '</td>
</tr>
<tr>
<td><b>Email Address - </b></td>
<td>' . $email . '</td>
</tr>
<tr>
<td><b>Message - </b></td>
<td>' . $message . '</td>
</tr>
</table>
</body>
</html>';
}
if(isset($_POST['pop_phone'])) {
$name = $_POST['name'];
$phone = $_POST['pop_phone'];
$message = $_POST['message'];
$html = '<html>
<head>
<title>Booking Details</title>
<style>
table {
width: 100%;
margin-bottom: 1rem;
color: #212529;
border-collapse: collapse;
}
table td, table th {
padding: 0.75rem;
vertical-align: top;
border-top: 1px solid #dee2e6;
}
</style>
</head>
<table>
<tr>
<td><b>Name - </b></td>
<td>' . $name . '</td>
</tr>
<tr>
<td><b>Phone Number - </b></td>
<td>' . $phone . '</td>
</tr>
<tr>
<td><b>Message - </b></td>
<td>' . $message . '</td>
</tr>
</table>
</body>
</html>';
}
// echo $html;
// exit();
$mail=new PHPMailer();
$mail->isSMTP();
$mail->Host='smtp.hostinger.com';
$mail->Port=465;
$mail->SMTPSecure="ssl";
$mail->SMTPAuth=true;
$mail->Username="info@theurbancabs.in";
$mail->Password="THRUrabanca@4345@";
$mail->setFrom("info@theurbancabs.in");
$mail->addAddress('theurbancabservice@gmail.com');
$mail->isHTML(true);
$mail->Subject="Booking Details";
$mail->Body=$html;
if($mail->send()){
echo '<script language="javascript">';
echo 'alert("We have received your information. Our team will contact you soon! Thankyou..."); location.href="index.php"; ';
echo '</script>';
}else{
echo '<script language="javascript">';
echo 'alert("Oops something went wrong!"); location.href="index.php"; ';
echo '</script>';
}
?>