stewartwebb
Programmer
Hi All,
I call this line of code on onKeyUp from a text box:-
The code works as I want it too, it removes any non numeric characters that have been entered.
Can someone let me know how I can adjust this line so that it removes non numeric characters but also ignores a decmial point?
Thanks
Stewart.
I call this line of code on onKeyUp from a text box:-
Code:
myInput.value = myInput.value.replace(/\D*|./g, "")
The code works as I want it too, it removes any non numeric characters that have been entered.
Can someone let me know how I can adjust this line so that it removes non numeric characters but also ignores a decmial point?
Thanks
Stewart.