Created
October 1, 2015 06:42
-
-
Save curtiswilkinson/bad56257eb14e48f0724 to your computer and use it in GitHub Desktop.
Remove all non-numerical values from fields
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
$("#bill_phone, #ship_phone").keyup(function () { | |
this.value = this.value.replace(/[^0-9\.]/g,''); | |
}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment