MDL-41115 fix username field label when allowing login via email

Thanks Marina for spotting this!
This commit is contained in:
Petr Škoda
2014-03-17 17:34:45 +08:00
parent 50f5c84359
commit b7679cdbfb
2 changed files with 7 additions and 1 deletions
+1
View File
@@ -1897,6 +1897,7 @@ $string['userdetails'] = 'User details';
$string['userfiles'] = 'User files';
$string['userlist'] = 'User list';
$string['username'] = 'Username';
$string['usernameemail'] = 'Username / email';
$string['usernameemailmatch'] = 'The username and email address do not relate to the same user';
$string['usernameexists'] = 'This username already exists, choose another';
$string['usernamelowercase'] = 'Only lowercase letters allowed';
+6 -1
View File
@@ -10,6 +10,11 @@ if (!empty($CFG->loginpasswordautocomplete)) {
} else {
$autocomplete = '';
}
if (empty($CFG->authloginviaemail)) {
$strusername = get_string('username');
} else {
$strusername = get_string('usernameemail');
}
?>
<div class="loginbox clearfix <?php echo $columns ?>">
<div class="loginpanel">
@@ -30,7 +35,7 @@ if (!empty($CFG->loginpasswordautocomplete)) {
?>
<form action="<?php echo $CFG->httpswwwroot; ?>/login/index.php" method="post" id="login" <?php echo $autocomplete; ?> >
<div class="loginform">
<div class="form-label"><label for="username"><?php print_string("username") ?></label></div>
<div class="form-label"><label for="username"><?php echo($strusername) ?></label></div>
<div class="form-input">
<input type="text" name="username" id="username" size="15" value="<?php p($frm->username) ?>" />
</div>