The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End PHP Form Question(s) Re: PHP Form Question(s)


Well, in looking at your form code on, you have this.

There are 2 problems i see with this form code.

1. contactFormprocess.php does not exist on your server. I get a 404 page when i click submit.

2. your enctype=”text/plain” will not submit anything to your php file.

Delete your enctype=”text/plain”. You dont need it at all.
Create contactFormprocess.php on your server and insert the latest send.php code I’m including here.

$email = $_POST;
$questions = $_POST;
// subject
$subject = 'Request for Information';

// HTML message
$message = '

' . $email . ' sent you a message.

' . $email. '

'. $questions .'


// To send HTML mail, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "rn";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "rn";

// Additional headers. FILL IN YOUR EMAIL HERE
$headers .= 'To: [email protected]' . "rn";
$headers .= 'From: My Web Site ' . "rn";
$headers .= 'Reply-To: <' . $_POST . '>' . "rn";
// Mail it
mail($to, $subject, $message, $headers);
//Send them back to the form page with a success message.
// From here is the html to the success page after e-mail was $theResults = <<< EOD

My Web Site/contact

Your request for additional information has successfully been forwarded.

Thank you for your interest in My Web Site.

You can expect a prompt response.

echo "$theResults";