jQuery: how to filter out non-character keys on keypress event?
The selected answer for this question is not complete. It does not handle the case where a character key is being pressed in combination with a modifier key (e.g. CTRL–A). Try, for example, typing CTRL–A using firefox with the following code. The current answer will consider it as a character: HTML: <input placeholder=”Try typing CTRL-A …