Guest User

Untitled

a guest
Oct 17th, 2017
50
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1. <!-- This Jscript is for selecting only numbers -->
  2. <script language="JavaScript">
  3. function onlyNumbers(evt) {
  4. var e = event || evt; // for trans-browser compatibility
  5. var charCode = e.which || e.keyCode;
  6. if (charCode > 31 && (charCode < 48 || charCode > 57))
  7. return false;
  8. return true;
  9. }
  10. </script>
Add Comment
Please, Sign In to add comment