The form is:
<form id="form1" name="form1" method="post" action="feedback.php">
<table cellspacing="0" cellpadding="0" class="form">
<tr>
<td style="width:233px; height:107px"><table cellspacing="0" cellpadding="0">
<tr>
<td style="width:233px; height:23px"><input name="Name" type="text" id="Name" value="First Name "></td>
</tr>
<tr>
<td style="width:233px; height:23px"><input name="Surname" type="text" id="Surname" value="Surname "></td>
</tr>
<tr>
<td style="width:233px; height:23px"><input name="Phone Number" type="text" id="Phone Number" value="Phone "></td>
</tr>
<tr>
<td style="width:233px; height:23px"><p>
<input name="Email" type="text" id="Email" value="Email ">
The processor is
Code: Select all
<?
if (empty($_POST)) {
print "Error with form, please contact the webmaster.";
} else {
// Configuration Settings
$SendFrom = "Waiting List Application Form<info@a.co.uk>";
$SendTo = "info@a.co.uk";
$SubjectLine = " Web Site";
$ThanksURL = "thankyou2.html"; //confirmation page
$Divider = "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~";
// Build Message Body from Web Form Input
$MsgBody = @gethostbyaddr($REMOTE_ADDR) . "\n$Divider\n";
foreach ($_POST as $Field=>$Value)
$MsgBody .= "$Field: $Value\n";
$MsgBody .= $Divider . "\n" . $HTTP_USER_AGENT . "\n";
$MsgBody = htmlspecialchars($MsgBody); //make content safe
// Send E-Mail and Direct Browser to Confirmation Page
mail($SendTo, $SubjectLine, $MsgBody, "From: " . $SendFrom);
header("Location: $ThanksURL");
}
?>