Remove special characters integer input by enabling thousands separator

To whom it may concern: I looked for a while for a reliable way to validate integers (save a true number from an integer input without special characters) and I stumbled on the answer in a nice lil hack. Integer inputs will restrict special characters if you enable thousands separators. Give it a try. It’s seriously a life changing lil piece of magic. Doesn’t help everywhere, but where it does help (currency for instance) it’s a gamechanger.


That makes no sense whatsoever, but I was looking for a way to prevent users typing decimal values into integer input and that did the trick.

Thank you very much.