When I send a email by a PHP script the receivers sees two "from" addresses, like this
Subject: About this
From: me@example.com
From: me@web01.example.com
Receiver: you@example.com
How can I change or get the second from with the webserver out of there?
This problem occurs since the update of Apache and MySQL...
Before there wasn't a second from:
Any suggestions?
Here a little piece of PHP code what has been used.
// Class start
$mail = new PHPMailer();
$mail->IsHTML(true);
// From
$mail->From = $config['email'];
$mail->FromName = $config['name'];
// To
if(!is_array($email)){
$mail->ClearAddresses();
$mail->AddAddress($email);
$mail->Send();
} else{
foreach($email as $email){
$mail->ClearAddresses();
$mail->AddAddress($email);
$mail->Send();
If I take a look at email from before the update the Return Path + Sender (inside Header) are the same as the email adres. Like it should be.
But after the update the Return Path + Sender say me@web01.example.com so that looks like the problem?
I am now using SMTP and sendmail was giving these problems since the update. SMTP solved it.