$(document).ready(function(){

      $("input[type='text']").each(

      function(){
         $(this).keypress( function(e) {

                 var key = window.event ? e.keyCode : e.which;

                 if(key.toString() == "13"){

                     alert('Please click respective submit button as Enter key is disabled');
                     return false;
                 }
         });
    });
});
评论

您还没有登陆,登陆后可以发表评论哦!点击登陆