RE: Comment on ITS 2.0 specification WD - Uniquness of id value

Hi Norbert,

> <body>
>    <p id=p1 class=class1>text...</p>
>    <p id=p2 class=class2>text...</p>
>    <p id=p3 class=class1>text...</p>
> </body>
>
> and ITS rule
>
> <its:rules xmlns:its="http://www.w3.org/2005/11/its" version="2.0">
>    <its:idValueRule selector="//p[@class='class1']" idValue="its1"/> 
> </its:rules>
>
> If I understand correctly, this gives me an identifier "its1"

As Felix already pointed out, this example doesn't really attach ID values to the selected elements.

The rule:

<its:rules xmlns:its="http://www.w3.org/2005/11/its"
 xmlns:h="http://www.w3.org/1999/xhtml" version="2.0">
   <its:idValueRule selector="//h:p[@class='class1']" idValue="@id"/> 
</its:rules>

would be more in line with the expected usage of the data category. It associates the ID value 'p1' with the first element selected and 'p3' with the last one.

But in any case, In HTML, the attribute id is the one which does take precedence anyway, so the rule would be overridden for all three of the paragraphs in the example. This is defined in the second bullet of the GLOBAL section (http://www.w3.org/TR/2012/WD-its20-20121206/#idvalue-implementation).


> (and possibly xml:id, whose spec I couldn't find).

The specification for xml:id are here:
http://www.w3.org/TR/xml-id/


cheers,
-yves

Received on Monday, 21 January 2013 12:36:27 UTC