Dreaded Return-Path and mail()
| From: | Monty | Date: | Mon, 06 Jan 2003 11:37:24 +0000 |
| Subject: | Dreaded Return-Path and mail() | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-130385@lists.php.net to get a copy of this message | ||
Okay, I've read just about everything on the Internet about how the change
the Return-Path header in an e-mail sent using mail(), but, I STILL can't
get it to work. All e-mail sent via PHP says Return-Path: nobody@domain.com
and Received: (from nobody@localhost).
I have a Red Hat Linux 7.2 server running PHP 4.2.2. I've tried the
following and none of them worked:
+ I put the following in my Apache httpd.conf file:
php_admin_value sendmail_path "/usr/bin/sendmail -t -i -f me@domain.com"
I also tried this without -t and -i. None of them worked. I did remember to
re-start Apache each time so the settings took effect.
+ I tried adding "-f me@domain.com" as the fifth parameter for the mail()
command, but, that didn't make a difference either. Actually, as I have
other items for the fifth "header" parameter, I wasn't sure where the above
command should be placed. I tried at the beginning and end of other header
info I was placing, but, nothing seemed to work.
+ I added "nobody" to Sendmail's trusted users. No difference.
Is there anything else I can try? I want to avoid changing this in the
PHP.ini file because I don't want e-mail from all domains to look like it is
coming from a single domain, if possible.
Thanks!