diff --git a/htdocs/core/lib/security2.lib.php b/htdocs/core/lib/security2.lib.php index a131afa1c9b..d17b4348c55 100644 --- a/htdocs/core/lib/security2.lib.php +++ b/htdocs/core/lib/security2.lib.php @@ -589,3 +589,36 @@ function dolJSToSetRandomPassword($htmlname, $htmlnameofbutton = 'generate_token return $out; } + +/** + * Output the eye picto to show/hide a password HTML field. + * + * @param string $htmlname HTML name of element to insert key into + * @param string $htmlnameofinput HTML id of input field + * @return string HTML javascript code to set a password + */ +function showEyeForField($htmlname, $htmlnameofinput) +{ + return ' + +'; +} diff --git a/htdocs/core/tpl/login.tpl.php b/htdocs/core/tpl/login.tpl.php index c2ef622e722..e87222f9b4c 100644 --- a/htdocs/core/tpl/login.tpl.php +++ b/htdocs/core/tpl/login.tpl.php @@ -306,28 +306,11 @@ if ($disablenofollow) { " name="password" class="flat input-icon-password minwidth150" value="" tabindex="2" autocomplete="" /> - + -