首页 > 代码库 > 按回车键提交表单

按回车键提交表单

document.onkeydown = function (e) {
var theEvent = window.event || e;
var code = theEvent.keyCode || theEvent.which;
if (code == 13) {
$("#add_submit").click();
}
}

按回车键提交表单