christydezignz
08-22-2009, 03:43 AM
I'm doing an EASY online form that should not be that hard, but it's giving me a error:
Parse error: syntax error, unexpected $end in D:\Hosting\4691023\html\newsletprocess.php on line 55
I don't understand . . this shouldn't be that hard? Can anybody help me?? What am I doing wrong?
<?php
/* Subject and Email Variables */
$emailSubject = 'Send me the e-newsletter!';
$webMaster = 'christy@phoenixdesignandprint.com';
/* Gathering Data Variables */
$nameField = $_POST['name'];
$companynameField = $_POST['companyname'];
$emailField = $_POST['email'];
$body = <<<EOD
<br><hr><br>
Name: $name <br>
Company Name: $companyname <br>
Email Address: $email <br>
EOD;
$headers = "From: $email\r\n";
$headers .= "Content-type: text/html\r\n";
$success = mail($webMaster, $emailSubject, $body, $headers);
/* Results rendered as HTML */
$theResults = <<<EOD
<html>
<title>Thank you for subscribing to our e-newsletter!</title>
<style type="text/css">
<!--
body p {
font-family: Verdana, Geneva, sans-serif;
}
body p {
text-align: center;
}
body p {
font-size: 12px;
}
-->
</style>
<body>
<p> </p>
<p> </p>
<p> </p>
<p>Thank you for subscribing to our e-newsletter!</p>
<p><a href="index.html">Click here to go back to home page</a></p>
</body>
</html>
EOD;
echo "$theResults";
?>
Parse error: syntax error, unexpected $end in D:\Hosting\4691023\html\newsletprocess.php on line 55
I don't understand . . this shouldn't be that hard? Can anybody help me?? What am I doing wrong?
<?php
/* Subject and Email Variables */
$emailSubject = 'Send me the e-newsletter!';
$webMaster = 'christy@phoenixdesignandprint.com';
/* Gathering Data Variables */
$nameField = $_POST['name'];
$companynameField = $_POST['companyname'];
$emailField = $_POST['email'];
$body = <<<EOD
<br><hr><br>
Name: $name <br>
Company Name: $companyname <br>
Email Address: $email <br>
EOD;
$headers = "From: $email\r\n";
$headers .= "Content-type: text/html\r\n";
$success = mail($webMaster, $emailSubject, $body, $headers);
/* Results rendered as HTML */
$theResults = <<<EOD
<html>
<title>Thank you for subscribing to our e-newsletter!</title>
<style type="text/css">
<!--
body p {
font-family: Verdana, Geneva, sans-serif;
}
body p {
text-align: center;
}
body p {
font-size: 12px;
}
-->
</style>
<body>
<p> </p>
<p> </p>
<p> </p>
<p>Thank you for subscribing to our e-newsletter!</p>
<p><a href="index.html">Click here to go back to home page</a></p>
</body>
</html>
EOD;
echo "$theResults";
?>