You've already forked phpmyadmin
mirror of
https://github.com/phpmyadmin/phpmyadmin.git
synced 2026-10-31 10:54:46 +03:00
Improved autofocus of login form fields
This commit is contained in:
@@ -3785,10 +3785,17 @@ AJAX.registerOnload('functions.js', function () {
|
||||
$("a._blank").prop("target", "_blank");
|
||||
/**
|
||||
* Reveal the login form to users with JS enabled
|
||||
* and focus the appropriate input field
|
||||
*/
|
||||
var $loginform = $('#loginform');
|
||||
$loginform.find('.js-show').show();
|
||||
$loginform.find('#input_username').select();
|
||||
if ($loginform.length) {
|
||||
$loginform.find('.js-show').show();
|
||||
if ($('#input_username').val()) {
|
||||
$('#input_password').focus();
|
||||
} else {
|
||||
$('#input_username').focus();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user