Answer the question
In order to leave comments, you need to log in
How to assign 2 handlers at once in jQuery: blur + keydown?
Sample code here: jsfiddle.net/8Jfne/29/
The bottom line is this: there is a set of inputs. When moving over them (using the keyboard or mouse), when leaving them, the value is checked. If not numerical, then we swear and return to editing the problematic input.
And now the problem:
In Chrome, if you enter a non-numeric value into the input and press Enter, then it works onkeydown - everything is fine. In FF and IE, both handlers work, so the error message appears twice (in FF, I generally have it three times, onblur works 2 times).
I would like to ask how to get out of this situation?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question