[whatwg] Attribute for holding private data for scripting
Anne van Kesteren
annevk at opera.com
Wed Apr 11 04:57:29 PDT 2007
On Wed, 11 Apr 2007 13:53:21 +0200, Sam Ruby <rubys at intertwingly.net>
wrote:
> Anne van Kesteren wrote:
>> On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby <rubys at intertwingly.net>
>> wrote:
>>> Per HTML5 section 8.1.2.3, however, such an attribute name would not
>>> be considered conformant.
>> Yes, only attributes defined in the specification are conformant.
>
> I was specifically referring to section 8.1.2.3. Let me call your
> attention to the following text:
>
> Attribute names use characters in the range U+0061 LATIN SMALL
> LETTER A .. U+007A LATIN SMALL LETTER Z, or, in uppercase, U+0041
> LATIN CAPITAL LETTER A .. U+005A LATIN CAPITAL LETTER Z, and U+002D
> HYPHEN-MINUS (-).
I think you should read the whole section. Allowing colons there wouldn't
make a difference.
>>> Despite this, later in document, in the description of "Attribute name
>>> state", no parse error is produced for this condition. Nor does the
>>> current html5lib parser produce a parse error with this data.
>>
>> Correct. We're not doing validation. Just tokenizing and building a
>> tree.
>
> In the process, parse errors are generally emitted in cases where
> individual characters are encountered which do not match the lexical
> grammar rules. Just not in this case.
The above are not the grammar rules. They are (normative) guidelines for
people writing or generating HTML. As far as I can tell there's no
normative grammar. Just a way to construct a conforming string and a way
to interpret a random string.
--
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>
More information about the whatwg
mailing list