mirror of
https://github.com/moodle/moodle.git
synced 2025-04-22 00:42:54 +02:00
MDL-26795 fix incorrect location of email change strings
AMOS BEGIN MOV [auth_emailchangecancel,auth_email],[emailchangecancel,core_auth] MOV [auth_emailchangepending,auth_email],[emailchangepending,core_auth] MOV [auth_emailupdate,auth_email],[emailupdate,core_auth] MOV [auth_emailnowexists,auth_email],[emailnowexists,core_auth] MOV [auth_emailupdatemessage,auth_email],[emailupdatemessage,core_auth] MOV [auth_emailupdatesuccess,auth_email],[emailupdatesuccess,core_auth] MOV [auth_emailupdatetitle,auth_email],[emailupdatetitle,core_auth] CPY [auth_emailnoemail,auth_email],[noemail,auth_ldap] AMOS END
This commit is contained in:
parent
92a387b467
commit
c6a074f867
@ -24,23 +24,8 @@
|
||||
*/
|
||||
|
||||
$string['auth_emaildescription'] = 'Email confirmation is the default authentication method. When the user signs up, choosing their own new username and password, a confirmation email is sent to the user\'s email address. This email contains a secure link to a page where the user can confirm their account. Future logins just check the username and password against the stored values in the Moodle database.';
|
||||
$string['auth_emailchangecancel'] = 'Cancel email change';
|
||||
$string['auth_emailchangepending'] = 'Change pending. Open the link sent to you at {$a->preference_newemail}.';
|
||||
$string['auth_emailnoemail'] = 'Tried to send you an email but failed!';
|
||||
$string['auth_emailnoinsert'] = 'Could not add your record to the database!';
|
||||
$string['auth_emailnowexists'] = 'The email address you tried to assign to your profile has been assigned to someone else since your original request. Your request for change of email address is hereby cancelled, but you may try again with a different address.';
|
||||
$string['auth_emailrecaptcha'] = 'Adds a visual/audio confirmation form element to the signup page for email self-registering users. This protects your site against spammers and contributes to a worthwhile cause. See http://recaptcha.net/learnmore.html for more details. <br /><em>PHP cURL extension is required.</em>';
|
||||
$string['auth_emailrecaptcha_key'] = 'Enable reCAPTCHA element';
|
||||
$string['auth_emailsettings'] = 'Settings';
|
||||
$string['auth_emailupdate'] = 'Email address update';
|
||||
$string['auth_emailupdatemessage'] = 'Dear {$a->fullname},
|
||||
|
||||
You have requested a change of your email address for your user account at {$a->site}. Please open the following URL in your browser in order to confirm this change.
|
||||
|
||||
{$a->url}';
|
||||
$string['auth_emailupdatesuccess'] = 'Email address of user <em>{$a->fullname}</em> was successfully updated to <em>{$a->email}</em>.';
|
||||
$string['auth_emailupdatetitle'] = 'Confirmation of email update at {$a->site}';
|
||||
$string['auth_changingemailaddress'] = 'You have requested a change of email address, from {$a->oldemail} to {$a->newemail}. For security reasons, we are sending you an email message at the new address to confirm that it belongs to you. Your email address will be updated as soon as you open the URL sent to you in that message.';
|
||||
$string['auth_invalidnewemailkey'] = 'Error: if you are trying to confirm a change of email address, you may have made a mistake in copying the URL we sent you by email. Please copy the address and try again.';
|
||||
$string['auth_outofnewemailupdateattempts'] = 'You have run out of allowed attempts to update your email address. Your update request has been cancelled.';
|
||||
$string['pluginname'] = 'Email-based self-registration';
|
||||
|
@ -502,7 +502,7 @@ class auth_plugin_ldap extends auth_plugin_base {
|
||||
events_trigger('user_created', $user);
|
||||
|
||||
if (! send_confirmation_email($user)) {
|
||||
print_error('auth_emailnoemail', 'auth_email');
|
||||
print_error('noemail', 'auth_ldap');
|
||||
}
|
||||
|
||||
if ($notify) {
|
||||
|
@ -114,6 +114,7 @@ $string['morethanoneuser'] = 'Strange! More than one user record found in ldap.
|
||||
$string['needbcmath'] = 'You need the BCMath extension to use grace logins with Active Directory';
|
||||
$string['needmbstring'] = 'You need the mbstring extension to change passwords in Active Directory';
|
||||
$string['nodnforusername'] = 'Error in user_update_password(). No DN for: {$a->username}';
|
||||
$string['noemail'] = 'Tried to send you an email but failed!';
|
||||
$string['notcalledfromserver'] = 'Should not be called from the web server!';
|
||||
$string['noupdatestobedone'] = "No updates to be done\n";
|
||||
$string['nouserentriestoremove'] = "No user entries to be removed\n";
|
||||
|
@ -60,6 +60,17 @@ $string['auth_user_creation'] = 'New (anonymous) users can create user accounts
|
||||
$string['auth_usernameexists'] = 'Selected username already exists. Please choose a new one.';
|
||||
$string['auto_add_remote_users'] = 'Auto add remote users';
|
||||
$string['createpasswordifneeded'] = 'Create password if needed';
|
||||
$string['emailchangecancel'] = 'Cancel email change';
|
||||
$string['emailchangepending'] = 'Change pending. Open the link sent to you at {$a->preference_newemail}.';
|
||||
$string['emailnowexists'] = 'The email address you tried to assign to your profile has been assigned to someone else since your original request. Your request for change of email address is hereby cancelled, but you may try again with a different address.';
|
||||
$string['emailupdate'] = 'Email address update';
|
||||
$string['emailupdatemessage'] = 'Dear {$a->fullname},
|
||||
|
||||
You have requested a change of your email address for your user account at {$a->site}. Please open the following URL in your browser in order to confirm this change.
|
||||
|
||||
{$a->url}';
|
||||
$string['emailupdatesuccess'] = 'Email address of user <em>{$a->fullname}</em> was successfully updated to <em>{$a->email}</em>.';
|
||||
$string['emailupdatetitle'] = 'Confirmation of email update at {$a->site}';
|
||||
$string['enterthenumbersyouhear'] = 'Enter the numbers you hear';
|
||||
$string['enterthewordsabove'] = 'Enter the words above';
|
||||
$string['errormaxconsecutiveidentchars'] = 'Passwords must have at most {$a} consecutive identical characters.';
|
||||
|
@ -169,7 +169,7 @@ if ($usernew = $userform->get_data()) {
|
||||
$usernew->preference_newemailattemptsleft = 3;
|
||||
$a->oldemail = $usernew->email = $user->email;
|
||||
|
||||
$email_changed_html = $OUTPUT->box(get_string('auth_changingemailaddress', 'auth_email', $a), 'generalbox', 'notice');
|
||||
$email_changed_html = $OUTPUT->box(get_string('auth_changingemailaddress', 'auth', $a), 'generalbox', 'notice');
|
||||
$email_changed_html .= $OUTPUT->continue_button("$CFG->wwwroot/user/view.php?id=$user->id&course=$course->id");
|
||||
$email_changed = true;
|
||||
}
|
||||
@ -225,8 +225,8 @@ if ($usernew = $userform->get_data()) {
|
||||
$a->site = $SITE->fullname;
|
||||
$a->fullname = fullname($user, true);
|
||||
|
||||
$emailupdatemessage = get_string('auth_emailupdatemessage', 'auth_email', $a);
|
||||
$emailupdatetitle = get_string('auth_emailupdatetitle', 'auth_email', $a);
|
||||
$emailupdatemessage = get_string('emailupdatemessage', 'auth', $a);
|
||||
$emailupdatetitle = get_string('emailupdatetitle', 'auth', $a);
|
||||
|
||||
//email confirmation directly rather than using messaging so they will definitely get an email
|
||||
if (!$mail_results = email_to_user($temp_user, get_admin(), $emailupdatetitle, $emailupdatemessage)) {
|
||||
|
@ -106,9 +106,9 @@ function useredit_shared_definition(&$mform, $editoroptions = null) {
|
||||
|
||||
// Do not show email field if change confirmation is pending
|
||||
if (!empty($CFG->emailchangeconfirmation) and !empty($user->preference_newemail)) {
|
||||
$notice = get_string('auth_emailchangepending', 'auth_email', $user);
|
||||
$notice = get_string('emailchangepending', 'auth', $user);
|
||||
$notice .= '<br /><a href="edit.php?cancelemailchange=1&id='.$user->id.'">'
|
||||
. get_string('auth_emailchangecancel', 'auth_email') . '</a>';
|
||||
. get_string('emailchangecancel', 'auth') . '</a>';
|
||||
$mform->addElement('static', 'emailpending', get_string('email'), $notice);
|
||||
} else {
|
||||
$mform->addElement('text', 'email', get_string('email'), 'maxlength="100" size="30"');
|
||||
|
@ -40,7 +40,7 @@ if (!$user = $DB->get_record('user', array('id' => $id))) {
|
||||
$preferences = get_user_preferences(null, null, $user->id);
|
||||
$a = new stdClass();
|
||||
$a->fullname = fullname($user, true);
|
||||
$stremailupdate = get_string('auth_emailupdate', 'auth_email', $a);
|
||||
$stremailupdate = get_string('emailupdate', 'auth', $a);
|
||||
|
||||
$PAGE->set_title(format_string($SITE->fullname) . ": $stremailupdate");
|
||||
$PAGE->set_heading(format_string($SITE->fullname) . ": $stremailupdate");
|
||||
@ -52,7 +52,7 @@ if (empty($preferences['newemailattemptsleft'])) {
|
||||
|
||||
} elseif ($preferences['newemailattemptsleft'] < 1) {
|
||||
cancel_email_update($user->id);
|
||||
$stroutofattempts = get_string('auth_outofnewemailupdateattempts', 'auth_email');
|
||||
$stroutofattempts = get_string('auth_outofnewemailupdateattempts', 'auth');
|
||||
echo $OUTPUT->box($stroutofattempts, 'center');
|
||||
|
||||
} elseif ($key == $preferences['newemailkey']) {
|
||||
@ -62,7 +62,7 @@ if (empty($preferences['newemailattemptsleft'])) {
|
||||
|
||||
// Detect duplicate before saving
|
||||
if ($DB->get_record('user', array('email' => $user->email))) {
|
||||
$stremailnowexists = get_string('auth_emailnowexists', 'auth_email');
|
||||
$stremailnowexists = get_string('emailnowexists', 'auth');
|
||||
echo $OUTPUT->box($stremailnowexists, 'center');
|
||||
echo $OUTPUT->continue_button("$CFG->wwwroot/user/view.php?id=$user->id");
|
||||
} else {
|
||||
@ -72,7 +72,7 @@ if (empty($preferences['newemailattemptsleft'])) {
|
||||
$authplugin->user_update($olduser, $user);
|
||||
events_trigger('user_updated', $user);
|
||||
$a->email = $user->email;
|
||||
$stremailupdatesuccess = get_string('auth_emailupdatesuccess', 'auth_email', $a);
|
||||
$stremailupdatesuccess = get_string('emailupdatesuccess', 'auth', $a);
|
||||
echo $OUTPUT->box($stremailupdatesuccess, 'center');
|
||||
echo $OUTPUT->continue_button("$CFG->wwwroot/user/view.php?id=$user->id");
|
||||
}
|
||||
@ -80,7 +80,7 @@ if (empty($preferences['newemailattemptsleft'])) {
|
||||
} else {
|
||||
$preferences['newemailattemptsleft']--;
|
||||
set_user_preference('newemailattemptsleft', $preferences['newemailattemptsleft'], $user->id);
|
||||
$strinvalidkey = get_string('auth_invalidnewemailkey', 'auth_email');
|
||||
$strinvalidkey = get_string('auth_invalidnewemailkey', 'auth');
|
||||
echo $OUTPUT->box($strinvalidkey, 'center');
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user