showing results for - "jquery only number allowed to 10 digit"
Mattia
07 Jul 2019
1<script type="text/javascript">
2  $(document).ready(function() {	
3  $("#phone_work").attr("maxlength", "10");
4  $("#phone_work").keypress(function(e) {
5    var kk = e.which;
6    if(kk < 48 || kk > 57)
7      e.preventDefault();
8  });
9});
10</script>