[whatwg] Custom attributes [was: Adding a src attribute to all elements]

Tab Atkins Jr. jackalmage at gmail.com
Wed Nov 4 08:03:26 PST 2009

On Wed, Nov 4, 2009 at 6:25 AM, Aryeh Gregor <Simetrical+w3c at gmail.com> wrote:
> On Wed, Nov 4, 2009 at 5:57 AM, Markus Ernst <derernst at gmx.ch> wrote:
>> While experimenting with the validator (at validator.w3.org), I found that
>> it does actually not complain about <h1 src="whatever.gif">. Thus, Tab's
>> example would be perfectly valid. The validator even seems to accept any
>> custom attribute name on any element - this is said to be valid HTML5:
>> . . .
>> Is this a mistake in the validator, due to its experimental state, or is
>> there something missing in the spec?
> A mistake in the validator.  http://validator.nu/ gives the correct
> answer: it's invalid.  You need to prefix custom attributes with
> "data-".

And/or write an "applicable specification" that defines the attribute
and becomes accepted enough by the community to be recognized by


More information about the whatwg mailing list