I would want the function to detect whether there is text in a text field typed in by a user. Not necessarily keyup. I wouldn't want it to fire every time I type in the field. I would want it to detect whether there is text in the field or not.
2 Answers
html <input> tags including type='text' support the onchange event. The onchange event occurs when the value of an element has been changed.
I wouldn't want it to fire every time I type in the field.
in this case, when exactly would you want it to be triggered? onblur event occurs when an object loses focus.
1 Comment
jeremy-denis
for me it's the proper way wait that the element have really change and after check the lenght or the value to determine if it's empty or filled
inputevent?