1 //按下enter键,则等同于点击登录按钮 2 document.onkeydown=function(e){ 3 var e=window.event?window.event:e; 4 if(e.keyCode==13){ 5 document.getElementById(‘submitbtn‘).click(); 6 } 7 }
2022-05-15 14:45:53
1 //按下enter键,则等同于点击登录按钮 2 document.onkeydown=function(e){ 3 var e=window.event?window.event:e; 4 if(e.keyCode==13){ 5 document.getElementById(‘submitbtn‘).click(); 6 } 7 }