hyperform icon indicating copy to clipboard operation
hyperform copied to clipboard

Element.validity.badInput is not resolved for input type text in IE 9

Open dipakchandranp opened this issue 7 years ago • 2 comments

I have an input field with type "text", and whenever blur event triggers in the field, the IE9 browser shows the following error message:

SCRIPT5007: Unable to get value of the property 'badInput': object is null or undefined

When I look through the plugin.js found the following code snippet:

/* check these for validity.badInput */
var input_checked = ['email', 'date', 'month', 'week', 'time', 'datetime', 'datetime-local', 'number', 'range', 'color'];

There is no text field included here. Is this something going to br fixed from hypreform?

dipakchandranp avatar Aug 08 '18 13:08 dipakchandranp

Thanks for the report!

Actually, there are two things going on here. It’s no oversight, that text is missing from the list you quote, because a plain text input can never suffer from a bad input constraint validation.

Nevertheless, the property element.validityState.badInput should be there and readable, even in IE9 (it’s just always false). I'll try to reproduce that error in an IE9 setup and report back, if I find anything.

Boldewyn avatar Aug 08 '18 16:08 Boldewyn

Could you test the new v0.9.21 in your setup, please? I’ve worked in exactly that area (validity.badInput wasn’t found in some instance), and the problem might be fixed now.

Boldewyn avatar Sep 21 '18 10:09 Boldewyn