From 8d1f813be62058ce1781e68fd875a148a22621ec Mon Sep 17 00:00:00 2001 From: Klaus Leithoff Date: Tue, 24 Aug 2010 08:36:54 +0000 Subject: [PATCH] USABILITY: if admin is setting the password,and retyping the intended password was not successful, the retype now gets deleted, and the inital password gets selected, after the alertbox is cleared away --- admin/templates/default/account_form.tpl | 4 +++- admin/templates/default/account_form_ldap.tpl | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/admin/templates/default/account_form.tpl b/admin/templates/default/account_form.tpl index b37f67943d..378e706f17 100644 --- a/admin/templates/default/account_form.tpl +++ b/admin/templates/default/account_form.tpl @@ -23,7 +23,9 @@ function check_password(id) if (password && (password2 || id == 'password2') && password != password2) { alert('{lang_passwds_unequal}'); - document.getElementById('password2').focus(); + document.getElementById('password2').value = ''; + document.getElementById('password').select(); + document.getElementById('password').focus(); return false; } return true; diff --git a/admin/templates/default/account_form_ldap.tpl b/admin/templates/default/account_form_ldap.tpl index 3970130928..0d6587fcb6 100644 --- a/admin/templates/default/account_form_ldap.tpl +++ b/admin/templates/default/account_form_ldap.tpl @@ -24,7 +24,9 @@ function check_password(id) if (password && (password2 || id == 'password2') && password != password2) { alert('{lang_passwds_unequal}'); - document.getElementById('password2').focus(); + document.getElementById('password2').value = ''; + document.getElementById('password').select(); + document.getElementById('password').focus(); return false; } return true;