<script type="text/javascript">
document.onkeydown = function(event) {//禁止没有回车事件的input触发submit提交表单事件,已有回车触发事件的input不受影响
switch (event.keyCode) {
case 13:
var obj = event.srcElement || event.target;
if (obj.tagName.toLowerCase() == "input") {
stopDefault(event);
}
break;
}
};
</script>