Javascropt-KeyCode

 当点回车时触发搜索事件

    $(document).keydown(function (e) {
                if (e.keyCode == 13) {
                    $("#txtUserName").focus();
                    $("#btnSearch").click;
                }
            });

posted @ 2013-08-20 09:27  黄忠  阅读(204)  评论(0编辑  收藏  举报