set focus on password field

This commit is contained in:
Roland Gruber 2005-05-15 13:14:45 +00:00
parent eb71557f54
commit adaae235e0
1 changed files with 11 additions and 0 deletions

View File

@ -110,6 +110,17 @@ function display_LoginPage($config_object,$profile)
<link rel="stylesheet" type="text/css" href="../style/layout.css">
</head>
<body>
<?php
// set focus on password field
echo "<script type=\"text/javascript\" language=\"javascript\">\n";
echo "<!--\n";
echo "window.onload = function() {\n";
echo "loginField = document.getElementsByName('passwd')[0];\n";
echo "loginField.focus();\n";
echo "}\n";
echo "//-->\n";
echo "</script>\n";
?>
<p align="center">
<a href="http://lam.sf.net" target="_blank"><img src="../graphics/banner.jpg" border="1" alt="LDAP Account Manager"></a>
</p>