Re: mail() - Return-Path
| From: | Malcolm White | Date: | Sat, 12 Jan 2002 12:36:58 +0000 |
| Subject: | Re: mail() - Return-Path | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-15696@lists.php.net to get a copy of this message | ||
1. Message sends.
2/3. The code used is as per the annotated on line PHP manual
cookieme@usa.net
11-Jan-2002 02:10
There used to be a note with a complete set of headers to use with the mail
function but somehow now its gone so here they are again hope it helps :)
$headers .= "From: Name<mail@server.com>\n";
$headers .= "X-Sender: <mail@server.com>\n";
$headers .= "X-Mailer: PHP\n"; //mailer
$headers .= "X-Priority: 3\n"; //1 UrgentMessage, 3 Normal
$headers .= "Return-Path: <mail@server.com>\n";
//Uncomment this to send html format
//$headers .= "Content-Type: text/html; charset=iso-8859-1\n";
//$headers .= "cc: birthdayarchive@php.net\n"; // CC to
//$headers .= "bcc: mail@server.com"; // BCCs to, separete
multiple with commas mail@mail.com, mail2@mail.com
Regards
P.A. Luis Tena O.
Mexico city.
4. No error messages. An email constructed as above sends perfectly - but
the return path defaults to the apache user (in my case www) not the
supplied return path. I tested the header construction by changing
Return-Path: to X-Path: and the X-Path: header appears correctly. I am not
sure but it seams that the real Return-Path is not overidable.
I hope this is clearer.
Malcolm
At 12:06 12/01/2002 -0000, you wrote:
>Malcolm,
>
>> I Have been trying to change the Return-Path: when using mail() but to no
>> success. I have followed the examples in the documentation. Is there any
>> hidden trick - Iam using apache 1.3.14, php 4.1.1 and sendmail 8.9.3.
>
>
>=There's been some grouching on the lists about spam and vague questions -
How much detail have you given about
>this problem? Would it be acceptable to answer saying "Iam using apache
1.3.14, php 4.1.1 and sendmail 8.9.3.
>and it works fine"?
>
>=Fortunately I don't (use sendmail) so after grumbling away, let me say
that I do have systems that email
>(successfully) from PHP code and am interested in the topic (and did like
your precise subject line).
>
>1 if a msg is constructed (without Return-Path) does it send/receive to spec?
>2 which example/documentation?
>3 what is the pertinent PHP code?
>4 what is the errmsg-received/other symptoms?
>
>=dn
>
>
>
>--
>PHP Database Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net
>For additional commands, e-mail: php-db-help@lists.php.net
>To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
>