Re: Size attribute error on input tag in HTML5

I consulted the passages between
http://www.whatwg.org/specs/web-apps/current-work/multipage/number-state.html#number-state
and http://www.whatwg.org/specs/web-apps/current-work/multipage/number-state.html#range-state
(deriving, at the time of consultation, from the passages between
http://svn.whatwg.org/webapps/!svn/bc/6274/complete.html#number-state
and http://svn.whatwg.org/webapps/!svn/bc/6274/complete.html#range-state
). Regarding an “input” element that has a “type” attribute with the
value “number” and that has a “size” attribute, the key passage is
“The following content attributes must not be specified and do not
apply to the element: accept, alt, checked, dirname, formaction,
formenctype, formmethod, formnovalidate, formtarget, height,
maxlength, multiple, pattern, size, src, and width.” The W3C Markup
Validation Service issues poor reports on such violations. The
following can serve as the basis for an improvement to the reports of
the W3C Markup Validation Service.

“The ‘size’ attribute that appears on this ‘input’ element is invalid
because the element is in the Number state. The element is in the
Number state because the element has a ‘type’ attribute that has the
value ‘number’.”

Received on Monday, 27 June 2011 02:39:02 UTC