Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

In input.html [1] it says

>If the input element has a maximum allowed value length, then the length of the value of the element's value attribute must be equal to or less than the element's maximum allowed value length.

I'm a little bit confused, Which one should we follow?

[1] https://html.spec.whatwg.org/multipage/input.html#attr-input...



From 4.10.17.1 (https://html.spec.whatwg.org/multipage/form-control-infrastr...):

> A control's value is its internal state. As such, it might not match the user's current input.

The example goes on to describe cases where a browser might remove padding spaces from a field, or refuse to register (as a value) a text entry in a numeric field.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: