mettre le focus sur le champ approprié
Comment peux-on obliger le curseur à ce positionner dans une zone texte precise du fromulaire à son ouverture.
voici mon code
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
| if ($action == "connection")
{
echo "<form ID=\"monformulaire\" NAME=\"monformulaire\" method='post' action=\"connection.php\">";
echo "<center><TABLE CELLPADDING=2 CELLSPACING=2 border=0 >";
echo"<tr>";
echo"<td id='titretb' colspan=2 bgcolor=silver><b><font face=\"Tahoma\" size=\"-1\" ><center>Connection ADMINISTRATEUR</center></b></font></td>";
echo"</tr>";
echo"<tr>";
echo"<td width=250 bgcolor=\"#DEE3E7\"> Entrez votre login : </td>";
echo"<td width=250 bgcolor=\"#DEE3E7\"><center><input type=TEXT ID=\"login\" size=15 name=\"login\" style=\"width:125;\"></center></td>";
echo"</tr>";
echo"<td width=250 bgcolor=\"#DEE3E7\"> Entrez votre pass : </td>";
echo"<TD width=250 bgcolor=\"#DEE3E7\"><center><input type=\"password\" size=15 name=pass style=\"width:125;\"></center></td>";
echo"</tr>";
echo"<tr>";
echo"<td width=250 class='comment' bgcolor=\"#DEE3E7\">Vous etes sur le point de vous connecter en tant qu <font color=#004080><strong>administarteur</strong></font>";
echo"<td width=250 bgcolor=\"#DEE3E7\"><center><input type=SUBMIT value=Connection></center>";
echo"</tr>";
echo"</table></center></form>";
echo"<script type=\"text/javascript\">
document.monformulaire.login.focus();
</script>";
} |
merci d avance