
PK 
<?php
/**
* Requires the "PHP Email Form" library
* The "PHP Email Form" library is available only in the pro version of the template
* The library should be uploaded to: vendor/php-email-form/php-email-form.php
* For more info and help: https://bootstrapmade.com/php-email-form/
*/
// Replace contact@example.com with your real receiving email address
$contact->ajax = true;
$name = !empty($_POST['name'])?trim($_POST['name']):"";
$email = !empty($_POST['email'])?trim($_POST['email']):"";
$mobile = !empty($_POST['mobile'])?trim($_POST['mobile']):"";
$subject = !empty($_POST['subject'])?trim($_POST['subject']):"";
$message = !empty($_POST['message'])?trim($_POST['message']):"";
function sendmail($name,$from,$to,$sendmessage){
$to = 'info@ingenuitybsp.com';
$from = 'Ingenuity Contact <info@ingenuitybsp.com>';
$subject = 'Ingenuity Website Contact Enquiry';
$headers = 'MIME-Version: 1.0' . "\r\n";
//$headers .= "BCC: indusinfotek.vinay@gmail.com\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
$headers .= 'From:'.$from. "\r\n" .
'Reply-To: ' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
$message = $sendmessage;
mail($to, $subject, $message, $headers);
}
if(!empty($message)){
$contactmail='<table cellpadding="0" cellspacing="0" style="width:600px; margin:0px auto; color:#7b7b7c; vertical-align:middle; font-family:Arial, Helvetica, sans-serif; font-size:16px;">
<tr>
<td style="text-align:center;"><a href="https://ingenuitybsp.com/"><img src="https://ingenuitybsp.com/assets/images/logo.png" /></a></td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td style="color:#333;"><strong>Hi, Admin</strong></td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td>You have been received a query.</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" style="width:600px; margin:0px auto; color:#7b7b7c; vertical-align:top; font-family:Arial, Helvetica, sans-serif; font-size:14px; line-height:22px;">
<tr>
<td> </td>
</tr>
<tr>
<td style="color:#333;" colspan="3"><strong>Contact Details</strong></td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td width="200px;">Name</td>
<td width="20px;">:</td>
<td width="380px;">'.$name.'</td>
</tr>
<tr>
<td width="200px;">Email Address</td>
<td width="20px;">:</td>
<td width="380px;">'.$email.'</td>
</tr>
<tr>
<td width="200px;">Phone No.</td>
<td width="20px;">:</td>
<td width="380px;">'.$mobile.'</td>
</tr>
<tr>
<td width="200px;">Subject</td>
<td width="20px;">:</td>
<td width="380px;">'.$subject.'</td>
</tr>
<tr>
<td width="200px;">Message</td>
<td width="20px;">:</td>
<td width="380px;"><p>'.$message.'</p></td>
</tr>
</table>';
//print_r($contactmail); exit;
sendmail($name,$email,$to,$contactmail);
}
// Uncomment below code if you want to use SMTP to send emails. You need to enter your correct SMTP credentials
/*
$contact->smtp = array(
'host' => 'example.com',
'username' => 'example',
'password' => 'pass',
'port' => '587'
);
*/
echo 'Sucessfully Submited';
?>


PK 99