note 81979 modified in function.mail by danbrown

From: Date: Mon, 20 Jun 2011 15:12:05 +0000
Subject: note 81979 modified in function.mail by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-180720@lists.php.net to get a copy of this message
If you are using the sendmail app from an exim package or something you don't really need to change the normal parameters PHP gives it (-t -i) as other posts described. I just added "-f myemail@example.com" and it worked. One thing that got me stuck for a few hours was trying to figure out why the return-path was set as the user (user running php) and not what I was setting it with the -f option then I later found at that in order to forcefully set the return-path the user account running the command must be in exim's trusted users configuration! It helps to add trusted_groups as well then everything works fine :) - Richard Sumilang --was-- If you are using the sendmail app from an exim package or something you don't really need to change the normal parameters PHP gives it (-t -i) as other posts described. I just added "-f myemail@foo.com" and it worked. One thing that got me stuck for a few hours was trying to figure out why the return-path was set as the user (user running php) and not what I was setting it with the -f option then I later found at that in order to forcefully set the return-path the user account running the command must be in exim's trusted users configuration! It helps to add trusted_groups as well then everything works fine :) - Richard Sumilang http://php.net/manual/en/function.mail.php

« previous php.notes (#180720) next »