it's actually not the headers that are a problem. It's that it's emailing me me, but in place of "Sender's Name: Me", it just says "Sender's Name:". (i.e. nothing is returned). THis is also the case with the color field.


From: [EMAIL PROTECTED]
To: "Dan Aloma" <[EMAIL PROTECTED]>
CC: [EMAIL PROTECTED]
Subject: Re: [PHP-INSTALL] Forms not parsing data
Date: Wed, 21 Apr 2004 16:15:53 -0400


I believe that you must seperate all headers with a \r\n, well that is per the RFC, but i also understand that your method, or at least just with a single \n will work. I would start to remove the extra headers argument and see if that is your problem. If you can mail with no extra headers try rebuilding them with \r\n. Personally, i've NEVER been able to send without \r\n ending each header.

HTH
Jeff



  So, I've installed PHP 4.3.6 and done "make test" and everything runs
fine. But now, when I run the scripts below, nothing happens. Actually, I
get an email with no returned values. This is a very common problem, but
nothing I've read can fix it. FYI, I have my register_globals set to the
default of off. I know it has to be something in the settings that's
causing
this, but I don't know what it could be. TIA.

INDEX.PHP----------------------------------
<form action="hello.php" method="POST">
Your first name <input type="text" name="name">
Your favorite color <input type="text" name="color">
Your email address <input type="text" name="email">
<input type="submit" value="Send Info">
</form>

HELLO.PHP-------------------------------
<?php
$senderemail = $_POST['email'];
$sendername = $_POST['name'];
$sendercolor = $_POST['color'];
$recipient = "[EMAIL PROTECTED]";
$subject = "Your subject line goes here";
$mailheader = "From: $senderemail\n";
$mailheader .= "Reply-To: $senderemail\n\n";
$message = "Sender's name: $sendername\n";
$message .= "Sender's favorite color: $sendercolor\n\n";
mail($recipient, $subject, $message, $mailheader) or die ("Failure");
?>

_________________________________________________________________
Watch LIVE baseball games on your computer with MLB.TV, included with MSN
Premium!
http://join.msn.com/?page=features/mlb&pgmarket=en-us/go/onm00200439ave/direct/01/







_________________________________________________________________
Watch LIVE baseball games on your computer with MLB.TV, included with MSN Premium! http://join.msn.com/?page=features/mlb&pgmarket=en-us/go/onm00200439ave/direct/01/

Reply via email to