mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-02-06 15:14:58 +00:00
use EmailNotify insteas of EmailUtils
This commit is contained in:
parent
72cf2a4283
commit
845017d9f5
|
@ -25,7 +25,7 @@ include("../inc/inc.Language.php");
|
|||
include("../inc/inc.ClassSession.php");
|
||||
include("../inc/inc.DBInit.php");
|
||||
include("../inc/inc.ClassUI.php");
|
||||
include("../inc/inc.ClassEmailUtils.php");
|
||||
include("../inc/inc.ClassEmailNotify.php");
|
||||
|
||||
include $settings->_rootDir . "languages/" . $settings->_language . "/lang.inc";
|
||||
|
||||
|
@ -53,11 +53,16 @@ if (empty($email) || empty($login)) {
|
|||
$user = $dms->getUserByLogin($login, $email);
|
||||
if($user) {
|
||||
if($hash = $dms->createPasswordRequest($user)) {
|
||||
$emailobj = new SeedDMS_EmailUtils();
|
||||
$subject = "###SITENAME###: ".getMLText("password_forgotten_email_subject");
|
||||
$message = str_replace('###HASH###', $hash, getMLText("password_forgotten_email_body"));
|
||||
|
||||
$emailobj->sendPassword($settings->_smtpSendFrom, $user, $subject, $message);
|
||||
$emailobj = new SeedDMS_EmailNotify();
|
||||
$subject = "password_forgotten_email_subject";
|
||||
$message = "password_forgotten_email_body";
|
||||
|
||||
$params = array();
|
||||
$params['sitename'] = $settings->_siteName;
|
||||
$params['http_root'] = $settings->_httpRoot;
|
||||
$params['hash'] = $hash;
|
||||
$params['url_prefix'] = "http".((isset($_SERVER['HTTPS']) && (strcmp($_SERVER['HTTPS'],'off')!=0)) ? "s" : "")."://".$_SERVER['HTTP_HOST'].$settings->_httpRoot;
|
||||
$emailobj->toIndividual($settings->_smtpSendFrom, $user, $subject, $message, $params);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user