i could swear i posted a reply to this 15 mins ago, strange :bemused:
Sorry m8 you lost me there. Here is the script that giving me the grief.
//Headers to allow for html coding
$headers = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
//Set multi line text
function breakIntoLines($txt, $lineLength){
$txt .= " ";
$lines = array();
while (strlen($txt) > 0){
if (strlen($txt) >= $lineLength){
$line = substr($txt, 0, $lineLength);
}else{
$line = $txt;
}
$line = substr($line, 0 , strrpos($line, " "));
$lines[] = $line;
if (strlen($txt) > strlen($line)){
$txt = substr($txt, strlen($line)+1, strlen($txt));
}else{
$txt = "";
}
}
return $lines;
}
//
//
$userOwner = "Paul";
$modName = $_POST['modName'];
$yourName = $_POST['yourName'];
$yourAddy = $_POST['yourAddy'];
$yourAddy = $_POST['yourAdd'];
$yourTel = $_POST['yourTel'];
$yourDate = $_POST['yourDate'];
$msg = $_POST['yourInfo'];
$adminaddress = "test@innovativedesigns.me.uk";
//Site address
$siteaddress = "";
// Enter your company name or site name
$sitename = "";
// Get the date and time from your server to be displayed in the email
$date = date("d/m/Y H:i:s");
$msgs=implode("<br>", breakIntoLines($msg, 50));
$bod = "<style type='text/css'>
<!--
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
background-color: #F3F0EC;
}
.style1 {
color: #5a5a5a;
font-size: 11px;
font-family: tahoma;
text-decoration:none;
line-height: 15px;
}
.var_tags {
color: #d10000;
font-size: 11px;
font-family: tahoma;
}
.dash {
border-bottom-width: 1px;
border-top-style: none;
border-right-style: none;
border-bottom-style: dotted;
border-left-style: none;
border-bottom-color: #CCCCCC;
}
-->
</style></head>
<body>
<span class='style1'>Hi $userOwner,</span>
<table width='80%' height='225' border='0'>
<tr>
<td height='16' colspan='2' class='dash' scope='col'><table width='100%' border='0'>
<tr>
<td scope='col'><span class='style1'>A Booking request for</span> <span class='var_tags'>$modName</span> <span class='style1'>has been recieved.</span></td>
</tr>
</table></td>
</tr>
<tr>
<td width='21%' height='21'><div align='right' class='style1'>Name/Company Name:</div></td>
<td width='79%' class='var_tags'>$yourName</td>
</tr>
<tr>
<td height='21'><div align='right' class='style1'>Email address: </div></td>
<td class='var_tags'>$yourAddy</td>
</tr>
<tr>
<td height='21'><div align='right' class='style1'>Contact number:</div></td>
<td class='var_tags'>$yourTel</td>
</tr>
<tr>
<td height='16' valign='top' class='style1'><div align='right'>Address:</div></td>
<td rowspan='2' valign='top' class='var_tags'>$yourAdd</td>
</tr>
<tr>
<td height='21'> </td>
</tr>
<tr>
<td height='21'><div align='right' class='style1'>Date of booking: </div></td>
<td class='var_tags'>$yourDate</td>
</tr>
<tr>
<td height='16' valign='top'><div align='right' class='style1'>Assignment information:</div></td>
<td rowspan='2' valign='top' class='var_tags'>$yourInfo</td>
</tr>
<tr>
<td height='21'> </td>
</tr>
<tr>
<td height='22' colspan='2' class='dash'> </td>
</tr>
</table>
<table width='80%' border='0'>
<tr>
<td scope='col'><span class='style1'>Email was sent on:</span> <span class='var_tags'>$date </span></td>
</tr>
</table>
</body>
</html>";
mail("$adminaddress","Model booking request",$bod,$headers."FROM:$adminaddress");
//This sends a thank you email to your visitor
mail("$yourAddy","Thank You $yourName, email recieved",
"Hi $yourName,<br/>
Your email has been recieved and someone will be<br />
in contact with you soon.<br /><br />
Kind regards,
$sitename<br/>
$siteaddress",$headers."FROM:$adminaddress");
echo "&retval=1&";
Thanks for any help