Re: Mail From option in PHP.ini
| From: | CPT John W. Holmes | Date: | Fri, 18 Jul 2003 15:08:32 +0000 |
| Subject: | Re: Mail From option in PHP.ini | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-155775@lists.php.net to get a copy of this message | ||
> Ok, I want to specify who the mail is coming from by using the
sendmail_path
> option in the PHP.ini. I've added the -fme@mydomain.com to it, but I want
> to be able to dynmaically change me@mydomain.com to you@mydomain.com or
> whatever else. Anyone have any ideas how I can do this? I'm pulling the
> e-mail I'd like to change it to from a MySQL database but can I rewrite
the
> php.ini file on the fly or am I stuck. Any help is greatly appreciated.
Why not just put it in the extra headers?
$headers .= "From: $email_address_from_your_database\r\n";
Or you could possibly use ini_set() to change the php.ini setting.
---John Holmes...