[whatwg] Constraint validation feedback (various threads)

Anne van Kesteren annevk at opera.com
Tue Nov 16 07:35:33 PST 2010


On Tue, 16 Nov 2010 16:04:08 +0100, Mounir Lamouri  
<mounir.lamouri at gmail.com> wrote:
> There is a LinkedIn form broken because of that: there are two fields
> with a non-HTML5 placeholder (ie. it's the value) which is set with
> .value="something" but the field has a maxlength set to 4 (it's a year).
> With a checkbox checked, one of this field will be hidden, with a value
> greater than the maxlength making the form always invalid.

Actually, that specific problem was addressed long ago based on feedback  
 from us:

"Constraint validation: If an element has a maximum allowed value length,  
and its dirty value flag is true, and the code-point length of the  
element's value is greater than the element's maximum allowed value  
length, then the element is suffering from being too long."

The "dirty value flag" is only true when the user has edited the control.


-- 
Anne van Kesteren
http://annevankesteren.nl/



More information about the whatwg mailing list