send email confirming pending registration #2916

This commit is contained in:
Tobias Diekershoff 2016-11-18 20:16:22 +01:00
parent 23bc0eae29
commit f4c52f5a0e
2 changed files with 28 additions and 0 deletions

View file

@ -378,6 +378,28 @@ function create_user($arr) {
}
/**
* @brief send registration confiŕmation with the intormation that reg is pending
*
* @param string $email
* @param string $sitename
* @param string $username
*/
function send_register_pending_eml($email, $sitename, $username) {
$body = deindent(t('
Dear %1$s,
Thank you for registering at %2$s. Your account is pending for approval by the administrator.
'));
$body = sprintf($body, $username, $sitename);
return notification(array(
'type' => "SYSTEM_EMAIL",
'to_email' => $email,
'subject'=> sprintf( t('Registration at %s'), $sitename),
'body' => $body));
}
/*
* send registration confirmation.
* It's here as a function because the mail is sent