Steve,

On Thu, 2005-10-27 at 21:19 -0400, steve miller wrote:
> Hi all.
> 
> Could use some help with php mail(). I am using this to send email, and 
> have having trouble getting the reply address right:
> 
> $mailto="$userstuff[3]";
> $mailfrom="[EMAIL PROTECTED]";

set $mailfrom as
$mailfrom="From: [EMAIL PROTECTED]
\nReply-To:[EMAIL PROTECTED]";

(above line may be wrapped)

take a look at http://us3.php.net/manual/en/function.mail.php
Here's some information form the above page about the 4th parameter to
mail function (which you have defined here as $mailfrom)
-----------
additional_headers (optional)
        
        String to be inserted at the end of the email header. 
        
        This is typically used to add extra headers (From, Cc, and Bcc).
        Multiple extra headers should be separated with a CRLF (\r\n). 
        
                Note:  When sending mail, the mail must contain a From
                header. This can be set with the additional_headers
                parameter, or a default can be set in php.ini. 
                
                Failing to do this will result in an error message
                similar to Warning: mail(): "sendmail_from" not set in
                php.ini or custom "From:" header missing. 
                
                Note:  If messages are not received, try using a LF (\n)
                only. Some poor quality Unix mail transfer agents
                replace LF by CRLF automatically (which leads to
                doubling CR if CRLF is used). This should be a last
                resort, as it does not comply with RFC 2822. 
---------------

HTH
-R'twick

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to