禁止表单中,回车键的提交功能。

    $(document).ready(function(){ 
        $("input").keydown(function(e){ 
            var curKey = e.which; 
            if(curKey == 13){ 
                var a=  $(this);
                var na="input[rel='"+(a.attr("rel")*1+1)+"']";
                var b=$(na).focus();
                return false; 
            } 
        }); 
    }); 
原文地址:https://www.cnblogs.com/axu92312/p/5629480.html