mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 09:49:28 +02:00
Update verification email
This commit is contained in:
parent
d968c93a50
commit
8fff05ad4d
1 changed files with 2 additions and 12 deletions
|
@ -2562,22 +2562,12 @@ if (typeof gtag !== \"function\") {
|
||||||
_error_log("sendVerificationLink: config is not a object " . json_encode($config));
|
_error_log("sendVerificationLink: config is not a object " . json_encode($config));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
$contactEmail = $config->getContactEmail();
|
|
||||||
$webSiteTitle = $config->getWebSiteTitle();
|
$webSiteTitle = $config->getWebSiteTitle();
|
||||||
/**
|
/**
|
||||||
* @var string $email
|
* @var string $email
|
||||||
*/
|
*/
|
||||||
$email = '';
|
$email = '';
|
||||||
$email = $user->getEmail();
|
$email = $user->getEmail();
|
||||||
$mail = new \PHPMailer\PHPMailer\PHPMailer();
|
|
||||||
setSiteSendMessage($mail);
|
|
||||||
//$mail->SMTPDebug = 4;
|
|
||||||
//Set who the message is to be sent from
|
|
||||||
$mail->setFrom($contactEmail, $webSiteTitle);
|
|
||||||
//Set who the message is to be sent to
|
|
||||||
$mail->addAddress($email);
|
|
||||||
//Set the subject line
|
|
||||||
$mail->Subject = __('Please Verify Your E-mail ') . $webSiteTitle;
|
|
||||||
|
|
||||||
$msg = sprintf(__("Hi %s"), $user->getName());
|
$msg = sprintf(__("Hi %s"), $user->getName());
|
||||||
$msg .= "<br><br>" . __($advancedCustomUser->verificationMailTextLine1);
|
$msg .= "<br><br>" . __($advancedCustomUser->verificationMailTextLine1);
|
||||||
|
@ -2586,8 +2576,8 @@ if (typeof gtag !== \"function\") {
|
||||||
$msg .= "<br><br>" . __($advancedCustomUser->verificationMailTextLine4);
|
$msg .= "<br><br>" . __($advancedCustomUser->verificationMailTextLine4);
|
||||||
$msg .= "<br><br>" . " <a href='{$global['webSiteRootURL']}objects/userVerifyEmail.php?code={$code}'>" . __("Verify") . "</a>";
|
$msg .= "<br><br>" . " <a href='{$global['webSiteRootURL']}objects/userVerifyEmail.php?code={$code}'>" . __("Verify") . "</a>";
|
||||||
|
|
||||||
$mail->msgHTML($msg);
|
$resp = sendSiteEmail($user->getEmail(), __('Please Verify Your E-mail ') . $webSiteTitle, $msg);
|
||||||
$resp = $mail->send();
|
|
||||||
if (!$resp) {
|
if (!$resp) {
|
||||||
_error_log("sendVerificationLink Error Info: {$mail->ErrorInfo}");
|
_error_log("sendVerificationLink Error Info: {$mail->ErrorInfo}");
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue