The from header has to be something like:
$mailheaders = "From: My Web Site <[EMAIL PROTECTED]>\n";

There has to be an email address in the from header.  It will show up like you 
want in your mail client.

-Jackson

On Thursday 14 August 2003 10:50, merryE wrote:
> I am using php 4 with apache in windows. I created a form in html with this
> code:
>
> <FORM method="POST" action="do_feedback.php">
> <p>your name: <INPUT type="text" NAME="sender_name" size=30></p>
> <p>your email: <INPUT type="text" NAME="sender_email" size=30></p>
> <p>Additional message:<br>
> <textarea name="message" cols=30 rows=5></textarea>
> </p>
> <INPUT type="submit" value="Send">
> </FORM>
>
> In php, I wrote this and save as do_feedback.php:
> <?php
> $msg = "Sender's Full Name:\t$sender_name\n";
> $msg .="Sender's E-mail:\t$sender_email\n";
> $msg .="Additional Message:\t$message\n\n";
>
> $mailheaders = "From: My Web Site\n";
> $mailheaders .="Reply-To: $sender_email\n\n";
>
> mail("[EMAIL PROTECTED]", "Feedback Form", $msg, $mailheaders);
>
> echo "<H1 align=center>Thank You, $sender_name</H1>";
> echo "<P align=center>We appreciate your feedback</P>";
>  ?>
> I got an error message ssy Undefined variable:sender_name
> bla bla bla and
> Warning: mail(): Failed to connect to mailserver at "localhost" port 25,
> verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in
> c:\program files\apache group\apache\htdocs\do_feedback.php on line 12
>
>  what's that means? Is anyone got a clue. please help

-- 
jackson miller
 
cold feet creative
615.321.3300 / 800.595.4401
[EMAIL PROTECTED]
 
 
cold feet presents Emma
the world's easiest email marketing
Learn more @  http://www.myemma.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to