Fatal error: Function name must be a string
I am having Trouble with something similar.
I am trying to create a php script for an online form, and the following appears:
Fatal error: Function name must be a string in D:\Hosting\3560291\html\contactformprocess.php on line 9
My code is the one below, can someone tell me whats wrong with it?
<?php
/* Subject and Email Variables */
$emailSubject = 'September 19th registration!';
$webMaster = 'cesct@ntplx.net';
/* Gathering Data Variables */
$emailFiled = $_POST('email');
$nameField = $_POST('name');
$phoneField = $_POST('phone');
$addressField = $_POST('address');
$hearField = $_POST('hear');
$travelersField = $_POST('travelers');
$commentsField = $_POST('comments');
$body = <<< EOD
<br><hr><br>
Email: $email <br>
Name: $name <br>
Phone: $phone <br>
Address: $address <br>
How did you hear about us?: $hear <br>
How many will be attending?: $travelers <br>
Comments: $comments <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>
<head>
<title>Connecticut Educational Services</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
body {
background-color: #f1f1f1;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 12px;
font-style: normal;
line-height: normal;
font-weight: normal;
color: #666666;
text-decoration: none;
}
-->
</style>
<head>
<div>
<div align="left">Thank you for your interest! Your email will be answered very soon!</div>
</div>
</body>
</html>
EOD;
echo "$theResults";