zoukankan      html  css  js  c++  java
  • 转载: js按回车键实现登陆

    转载网址:http://blog.csdn.net/mawenwu281107072139/article/details/4787258

    1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">  
    2. <html xmlns="http://www.w3.org/1999/xhtml" >  
    3. <head>  
    4. <title>Check Score</title>  
    5. <mce:script language="JavaScript"><!--  
    6.     function keyLogin(){  
    7.         if (event.keyCode==13)   //回车键的键值为13  
    8.              document.getElementById("input1").click(); //调用登录按钮的登录事件  
    9.         }  
    10. // --></mce:script>  
    11. </head>  
    12.   
    13. <body onkeydown="keyLogin();">  
    14.         <input type="text" />  
    15.         <input type="text" />  
    16.         <input type="text" /><input type="text" />  
    17.         <input type="text" /><input type="text" />  
    18.         <!--<input id="input1" value="登录" type="button" onclick="alert('调用成功!')">-->  
    19.         <img id="input1" onclick="alert('调用成功!')"/>  
    20. </body>  
    21.   
    22. </html>  
  • 相关阅读:
    set, unordered_set模板类
    C/C++ Bug记录
    win10远程连接
    C/C++缓冲区刷新问题
    hihocoder1711 评论框排版[并查集+set]
    makefile
    Virtual Table
    粤语
    xilinx SDK开发 GPIO使用API总结
    基于zynq 7020的串口UART中断实验
  • 原文地址:https://www.cnblogs.com/lraa/p/2918365.html
Copyright © 2011-2022 走看看