I have installed postfix with no config option.
I am trying to send email with php mail(); it works but it sends email with the default email of my dedicated server.
Are there anyway to tell postfix to follow the header set by mail function?
Thanks
Code
$from='[email protected]';
$fromname='my Website';
mail($mailto,$subject,$text,'From: ' . $fromname . ' <'.$from.'>');
Try using the -f and -r additional parameters to override the from header and return path respectively.
From the postfix sendmail man page:
If you have a million mail() and do not want to recode all your mail() functions... you can set in your php.ini the following... and it will universally set all you php mail() functions to use it.