I created an html contact form page and php contact process form page. Anyway, when you fill out the form, and click submit it will say "thanks for filling out the form!". I check my email address and see the form fields not filled in. It will say Email: Name: Company: but the fields will not be filled out. Why is that? I pasted below the php code for it. Is there anything else I need to show to answer this question???
So how do I fix my php code so that when i receive an email that the form fields will be filled out?????
<?php
/* Subject and Email Variables */
$emailSubject = 'Please show fields';
$webMaster = '[email protected]';
/*Gathering Data Variables */
$email - $_POST['email'];
$name - $_POST['name'];
$contactphone - $_POST['contactphone'];
$yourcompany - $_POST['yourcompany'];
$service - $_POST['service'];
$details - $_POST['details'];
$body = <<<EOD
<br><hr><br>
Email: $email <br>
Name: $name <br>
Contact Phone: $contactphone <br>
Company Name: $yourcompany <br>
Service Interested In: $service <br>
Comments: $details <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>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>test</title>
</head>
<body>Thank you for your interest. We will reply to your email shortly!
</body>
</html>
EOD;
echo "$theResults";
?>
Can anyone just read the code and tell me? What do you mean by linux server?? How would I know if it was a linux server anyway? PLEASEEEEEEEEEEEEEEE
ok its kinda strange, when i put $email = $_POST['email']; <--when i put the equal signs, and i was unable to receive an email.... i put the dashs back in and im receiving the email but still no fields filled in, any other suggestions?
So how do I fix my php code so that when i receive an email that the form fields will be filled out?????
<?php
/* Subject and Email Variables */
$emailSubject = 'Please show fields';
$webMaster = '[email protected]';
/*Gathering Data Variables */
$email - $_POST['email'];
$name - $_POST['name'];
$contactphone - $_POST['contactphone'];
$yourcompany - $_POST['yourcompany'];
$service - $_POST['service'];
$details - $_POST['details'];
$body = <<<EOD
<br><hr><br>
Email: $email <br>
Name: $name <br>
Contact Phone: $contactphone <br>
Company Name: $yourcompany <br>
Service Interested In: $service <br>
Comments: $details <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>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>test</title>
</head>
<body>Thank you for your interest. We will reply to your email shortly!
</body>
</html>
EOD;
echo "$theResults";
?>
Can anyone just read the code and tell me? What do you mean by linux server?? How would I know if it was a linux server anyway? PLEASEEEEEEEEEEEEEEE
ok its kinda strange, when i put $email = $_POST['email']; <--when i put the equal signs, and i was unable to receive an email.... i put the dashs back in and im receiving the email but still no fields filled in, any other suggestions?