Add the ability to supply a default "from" email address for the "forgot password" feature, instead of using the same address as for the "to".

SVN:trunk[3213]
This commit is contained in:
Denis Flaven
2014-06-16 15:14:40 +00:00
parent a6d984e23f
commit 4fccf5c815
2 changed files with 14 additions and 0 deletions

View File

@@ -244,6 +244,11 @@ class LoginWebPage extends NiceWebPage
$oEmail = new Email();
$oEmail->SetRecipientTO($sTo);
$sFrom = MetaModel::GetConfig()->Get('forgot_password_from');
if ($sFrom == '')
{
$sFrom = $sTo;
}
$oEmail->SetRecipientFrom($sTo);
$oEmail->SetSubject(Dict::S('UI:ResetPwd-EmailSubject'));
$sResetUrl = utils::GetAbsoluteUrlAppRoot().'pages/UI.php?loginop=reset_pwd&auth_user='.urlencode($oUser->Get('login')).'&token='.urlencode($sToken);