Skip to content

Commit 6d49fc6

Browse files
committed
Fixes in welcome email.
1 parent c719dc0 commit 6d49fc6

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
From: ISPConfig <postmaster@localhost.localdomain>
12
Subject: Welcome to your new email account.
23

34
Welcome to your new email account. Your webmaster.

server/plugins-available/mail_plugin.inc.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -169,8 +169,10 @@ function user_insert($event_name,$data) {
169169
$tmp = file($conf['rootpath'].'/conf/mail/welcome_email_en.txt');
170170
}
171171

172-
$welcome_mail_subject = trim(substr($tmp[0],8));
172+
$welcome_mail_from = trim(substr($tmp[0],5));
173+
$welcome_mail_subject = trim(substr($tmp[1],8));
173174
unset($tmp[0]);
175+
unset($tmp[1]);
174176
$welcome_mail_message = trim(implode($tmp));
175177
unset($tmp);
176178

@@ -180,8 +182,8 @@ function user_insert($event_name,$data) {
180182
$mailHeaders = "MIME-Version: 1.0" . "\n";
181183
$mailHeaders .= "Content-type: text/plain; charset=utf-8" . "\n";
182184
$mailHeaders .= "Content-Transfer-Encoding: 8bit" . "\n";
183-
$mailHeaders .= "From: $welcomeFromName <$welcomeFromEmail>" . "\n";
184-
$mailHeaders .= "Reply-To: <$welcomeFromEmail>" . "\n";
185+
$mailHeaders .= "From: $welcome_mail_from" . "\n";
186+
$mailHeaders .= "Reply-To: $welcome_mail_from" . "\n";
185187
$mailTarget = $data["new"]["email"];
186188
$mailSubject = "=?utf-8?Q?" . imap_8bit($welcome_mail_subject) . "?=";
187189

0 commit comments

Comments
 (0)