document.onkeydown = function (e) { // 回車提交表單 // 兼容FF和IE和Opera var theEvent = window.event || e; var code = th