Hi,
I am making php from.Everhting is working fine.I am receving result as below.I want to space before Tel no.Please be advice how i can do. Thank you.
---------------------------------------------------
Email Result
--------------------------------------------------
General Info Request
Name: Khan
1665 Bloor Street
Mississauga
L4X3T4
Tel:647-290-0000
Email: hanyon@gmail.com
Best Time To Contact:11am
Message is:
Hi,
---------------------------------------------------
<?php
$name=$_POST['name'];
$phone=$_POST['phone'];
$email=$_POST['email'];
$contact_time=$_POST['Contact_Time'];
$address=$_POST['address'];
$city=$_POST['city'];
$postal=$_POST['postal'];
$message=$_POST['message'];
if($message=="")
{
$message="<b>no message</b>";
}
else
{
$message="<b>Message:</b><br>".$message;
}
$emailBody ="<HTML>\n"
."<head><title></title></head><body>\n"
."<table bordercolor=red border=\"1\" cellspacing=0 cellpadding=0>\n"
."<tr><td bgcolor=\"#e9e8d6\" colspan=2 align=center><h3>General Info Request</h3></td></tr>\n"
."<tr><td bgcolor=\"#ffffa0\" style=\"border:solid 1px #666666;\"><b>Name:</b>$name</td>
<tr><td bgcolor=\"#ffffa0\" style=\"border:solid 1px #666666;\"><b></b>$address</td>
<td bgcolor=\"#ffffa0\" style=\"border:solid 1px #666666;\"><b></b>$city</td></tr>\n"
."<tr><td bgcolor=\"#d6d68c\" style=\"border:solid 1px #666666;\" colspan=2><b></b>$postal</td></tr>\n"
."<tr><td bgcolor=\"#ffffa0\" style=\"border:solid 1px #666666;\"><b>Tel:</b>$phone</td></tr>\n"
."<tr><td bgcolor=\"#d6d68c\" style=\"border:solid 1px #666666;\"><b>Email:</b>$email</td>
<td bgcolor=\"#d6d68c\" style=\"border:solid 1px #666666;\"><b>Best Time To Contact:</b>$contact_time</td></tr>\n"
."<tr><td bgcolor=\"#ffffa0\" style=\"border:solid 1px #666666;\" colspan=2>$message</td></tr>\n"
."</table></body></html>";
$emailTo = '"" <info@land.ca>'; //Enter your email instead of email@yourdomain.com
$emailSubject = "FREE DEMONSTRATION";
$emailSubject = preg_replace('/[\x00-\x1F]/', '', $emailSubject);
$emailFrom = $email;//from email
$emailFrom = preg_replace('/[\x00-\x1F]/', '', $emailFrom);
$emailHeader = "From: $emailFrom\n"
. "Reply-To: $emailFrom\n"
. "Return-Path: $emailFrom\n"
. "X-Sender: $emailFrom\n"
. "X-Mailer: PHP\n"
. "X-Priority: 3\n"
. "MIME-Version: 1.0\n"
. "Content-Type: text/html; charset=\"ISO-8859-1\"\n"
. "Content-Transfer-Encoding: base64\n"
. "\n";
$emailBody=chunk_split(base64_encode($emailBody));
mail($emailTo, $emailSubject, $emailBody, $emailHeader);
# Confirmation Email to User
$confEmailTo =$email;//from email
$confEmailTo = preg_replace('/[\x00-\x1F]/', '', $confEmailTo);
$confEmailSubject = "Confirmation ";
$confEmailSubject = preg_replace('/[\x00-\x1F]/', '', $confEmailSubject);
$confEmailBody = "Hello $fname,\n"
. "Thanks for your recent enquiry . We have received your message, we will contact you shortly - Grout Masters\n"
. "\n"
. "";
$confEmailHeader = "From: no-reply@yourdomain.com\n"//Enter your email instead of email@yourdomain.com
. "Reply-To: no-reply@yourdomain.com\n"//Enter your email instead of email@yourdomain.com
. "MIME-Version: 1.0\n"
. "Content-type: text/plain; charset=\"ISO-8859-1\"\n"
. "Content-transfer-encoding: 8bit\n";
mail($confEmailTo, $confEmailSubject, $confEmailBody, $confEmailHeader);
header("location:thankyou.html");//reload
?>