From 4650c3a4b618449831b78bceb38c7631c9c44b6a Mon Sep 17 00:00:00 2001 From: Nicolas Liautaud Date: Sun, 27 Jan 2019 13:55:22 +0100 Subject: [PATCH] fix #41 use no-reply@server as from header --- p01-contact/src/P01contact_Form.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/p01-contact/src/P01contact_Form.php b/p01-contact/src/P01contact_Form.php index 25997dc..e91ea5c 100644 --- a/p01-contact/src/P01contact_Form.php +++ b/p01-contact/src/P01contact_Form.php @@ -427,9 +427,8 @@ public function sendMail() private function mailHeaders($name, $email, $mime_boundary) { $encoded_name = $this->encodeHeader($name); - $headers = "From: $encoded_name"; + $headers = "From: $encoded_name \n"; if ($email) { - $headers .= " <$email>\n"; $headers .= "Reply-To: $encoded_name <$email>\n"; $headers .= "Return-Path: $encoded_name <$email>"; }