My code which is a mail form, gives me a parse error on line 92, which is the end <? tag...what could be the problem there?
<?
ob_start();
$name = $_POST['name'];
$addr = $_POST['addr'];
$tel = $_POST['tel'];
$email = $_POST['email'];
$username = $_POST['username'];
$despass = $_POST['despass'];
$type = $_POST['type'];
$functionality = $_POST['functionality'];
$sname = $_POST['sname'];
$otherinfo = $_POST['otherinfo'];
$admin = "Peter.Spokes@ultimatehosting.ath.cx\r\n";
$subject = $username . "Hosting Request:\r\n";
if((!$name) || (!$addr) || (!$tel) || (!$email) || (!$username) || (!$despass) || (!$type) || (!functionality) || (!sname) || (!otherinfo)) {
header("Location: mailform.php?error=1");
}
$message = "Hosting Request By:\r\n\r\n " . $username . "\r\n";
$message .= "-------------------------------\r\n";
$message .= "Name: " . $name . "\r\n";
$message .= "Address: " . $addr . "\r\n";
$message .= "Telephone: " .$tel . "\r\n";
$message .= "E-Mail: " .$email . "\r\n";
$message .= "-------------------------------\r\n";
$message .= "Desired User: " .$username . "\r\n";
$message .= "Desired Pass: " .$despass . "\r\n";
$message .= "Site Name: " .$sname . "\r\n";
$message .= "-------------------------------\r\n";
$message .= "Hosting Type: " . $type . "\r\n";
$message .= "Functionality: " . $functionality . "\r\n";
$message .= "Other Information: " . $otherinfo . "\r\n";
$to = "Peter.Spokes@ultimatehosting.ath.cx";
$subject = "Hosting Request By: " . $username . "\r\n";
$headers = "From: " . $email . "\r\n" . "Bcc: " . $bcc . "\r\n";
mail($to, $subject, stripslashes($message), $headers);
?>
<?php
function reply() {
$rep = <<<EOD
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
$headers .= "From: " . $admin . "\r\n" . "Bcc: " . $bcc . "\r\n";
<p><font color="#B60000" size="5" face="Arial, Helvetica, sans-serif"><strong>Hosting Request Completed</strong></font></p>
<p><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif">Thank you
for your hosting request. Your request will be reviewed and queued for creation by an administrator. Please remember that paying and secialist service accounts have priority in the creation queue and will be attended to before the free services. Please also note that by requesting any of our services, you agree to comply with the Terms of Service outlined on our website.</font></p>
<p><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif">Once you're hosting request has been reviewed, you will be contacted by an administrator to confirm you're details and activate you're hosting. Once activated, you're hosting will be available for use immediately</font></p>
<p><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif">If you have any comments or questions whatsoever, please visit our forums. Also, worth noting, if you have a future support request, you may use our ticket based support system which is located under the Support section on out website. </font></p>
<hr size="1">
<p><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif">Sincerely,</font></p>
<p><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif"> Peter Spokes,
</font></p>
<p><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif">Ultimate Hosting UK Management Team </font></p>
<hr size="1">
<div align="left"><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif"><br>
You are receiving this e-mail becuase you submited a request form on <a href="http://ultimatehosting.ath.cx" target="_blank">[url]http://ultimatehosting.ath.cx.[/url]</a></a></a></a>
THIS IS NOT SPAM. If you did not request this, send an e-mail to <a href="mailto<img src="images/smilies/redface.gif" border="0" alt="">Peter.Spokes@ultimatehosting.ath.cx">Peter.Spokes@ultimatehoating.ath.cx</a>
with subject "CANCEL REQUEST" and nothing in the body. <br>
</font><font color="#B60000" size="3" face="Arial, Helvetica, sans-serif"><br>
</font>
<hr size="1">
<div align="center"><font color="#B60000" size="3" face="Arial, Helvetica, sans-serif"><br>
</font><font color="#B60000" size="2" face="Arial, Helvetica, sans-serif"><font size="1">Copyright ©
2005 Ultimate Hosting UK. All Rights Reserved.<br>
Web Hosting Division<br>
<a href="http://ultimatehosting.ath.cx" target="_blank"><a href="http://ultimatehosting.ath.cx" target="_blank"><a href="http://www.stoneddevilinc.com" target="_blank"><a href="http://ultimatehosting.ath.cx" target="_blank">
</font></div>
</div>
EOD;
return $rep;
}
$replymessage = reply();
$replyto = $email;
$replysubject = "Hosting Request Received.\r\n";
$headers = "From: " . $admin . "\r\n" . "Bcc: " . $bcc . "\r\n";
mail($replyto, $replysubject, $replymessage, $headers);
header("Location: mailform.php?complete=1");
ob_end_flush();
?>