<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=shift_jis" />
<script language="javascript">
function onkeydown() {
if(event.keyCode == 13) {
document.getElementById("enter").click();
return false;
}
}
</script>
</head>
<body onLoad="document.getElementById('enter').focus()">
<input type="button" id="enter" value="enter" onclick="alert('enter');"/>
</body>
</html>
html按钮响应回车键
最新推荐文章于 2025-05-08 22:48:35 发布