Hello,
check out your php.ini file, in the section [mail function]. You probably have something like the following defined:
sendmail_path = /usr/sbin/sendmail -t -i
and pretty much all else commented out. So what happens is php's mail() function calls the sendmail binary (which is the mail injection command of postfix) and gives it the message. Because postfix doesn't trust local users, it discards the 'from' field and replaces it with the Linux userid of the calling process. In this case, it is 'Apache'.
What you need to do is make it use SMTP instead of the sendmail command. You will need to know the name of your SMTP server, which may be 'localhost' if your postfix is running as such. In the php.ini's [mail function] section, add:
SMTP =
smtp_port = 25
sendmail_from = [email protected]
The first two options will make PHP talk to the SMTP server directly, which implicitely trusts the information given to it; the last option sets the default sender email address to use.
Hope this helps,
Christophe