I am running this on an apache server I installed on my comp.
this is the form code, for mailform.php
Code: Select all
<form method="post" action="sendmail.php">
Email: <input type="text" name="email" /><br />
Message:<br />
<textarea name="message" rows="15" cols="40">
</textarea><br />
<input type="submit" />
</form>Code: Select all
<?
$email = $_REQUESTї'email'] ;
$message = $_REQUESTї'message'] ;
if (!isset($_REQUESTї'email'])) {
header( "Loacation: http://localhost/feedback.html" );
}
elseif (empty($email) || empty($message)) {
header( "Location: http://localhost/error.html" );
}
else {
mail( "Phatoutlaw@aol.com", "Feedback Form Results",
$message, "From: $email" );
header( "Location: http://localhost/thankyou.html" );
}
?>Warning: mail(): "sendmail_from" not set in php.ini or custom "From:" header missing in d:\program files\apache group\apache\htdocs\sendmail.php on line 15
Warning: Cannot modify header information - headers already sent by (output started at d:\program files\apache group\apache\htdocs\sendmail.php:15) in d:\program files\apache group\apache\htdocs\sendmail.php on line 16