ajout de l'expediteur du message dans l'adresse de retour- Retrun-Path du mail
This commit is contained in:
parent
0a87a3a0cb
commit
bd7c519426
4
cron.php
4
cron.php
@ -42,9 +42,9 @@
|
|||||||
$mailText = $dicoExpe[$p['indexText']] .EOL .EOL ;
|
$mailText = $dicoExpe[$p['indexText']] .EOL .EOL ;
|
||||||
print $objetMail . EOLH;
|
print $objetMail . EOLH;
|
||||||
print $mailText . EOLH;
|
print $mailText . EOLH;
|
||||||
envoiMail( $result['destMail'], $objetMail, $mailText, false);
|
envoiMail($result['expeMail'], $result['destMail'], $objetMail, $mailText, false);
|
||||||
sleep(1);
|
sleep(1);
|
||||||
envoiMail( $result['expeMail'], $objetMail, $mailText, true);
|
envoiMail("contact@avion-poe.me", $result['expeMail'], $objetMail, $mailText, true);
|
||||||
sleep(1);
|
sleep(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -86,7 +86,8 @@ function envoiMail($destinataire, $sujet, $text, $html=false, $cc='', $bcc='')
|
|||||||
$message->setBody($text);
|
$message->setBody($text);
|
||||||
//add date header
|
//add date header
|
||||||
$headers = $message->getHeaders();
|
$headers = $message->getHeaders();
|
||||||
$headers->addDateHeader('Your-Header', new DateTimeImmutable('3 days ago'));
|
//$headers->addDateHeader('Date', new DateTimeImmutable('3 days ago'));
|
||||||
|
$headers->addPathHeader('Return-Path', $expediteur);
|
||||||
if (!$mailer->send($message, $failures))
|
if (!$mailer->send($message, $failures))
|
||||||
{
|
{
|
||||||
echo "Failures:";
|
echo "Failures:";
|
||||||
|
Reference in New Issue
Block a user