Summary
The Itemid attribute is the unique, global identifier of an item.
The itemid attribute can only be specified on elements that have both itemscope and itemtype attributes. Also, the itemid can only be specified on elements with an itemscope attribute whose corresponding itemtype attribute specifies a vocabulary that supports global identifiers for items.
The exact meaning of a global identifier is determined by the itemtype vocabulary.The vocabulary can define whether multiple items with the same global identifier are allowed, and what the processing rules for that vocabulary are with respect to handling the case of multiple items with the same ID.
Note: The Whatwg.org definition of an itemid says that it must be a URL. This does not seem to be the case as the example below shows. Rather the defacto definition is that an itemid is a unique identifier, so a URN is appropriate. This inconsistency no doubt reflects the incomplete nature of the Microdata specification.
sEditExample
HTML
<dl itemscope itemtype="https://vocab.example.net/book" itemid="urn:isbn:0-330-34032-8"> <dt>Title <dd itemprop="title">The Reality Dysfunction <dt>Author <dd itemprop="author">Peter F. Hamilton <dt>Publication date <dd><time itemprop="pubdate" datetime="1996-01-26">26 January 1996</time> </dl>
Structured data
itemscope | itemtype: itemid |
https://vocab.example.net/book: urn:isbn:0-330-34032-8
|
|
itemprop | title | The Reality Dysfunction | |
itemprop | author |
Peter F. Hamilton
|
|
itemprop | pubdate | 1996-01-26 |
Result
{{ EmbedLiveSample('HTML', '', '', '', 'Web/HTML/Global_attributes/itemid') }}
Specifications
Specification | Status |
---|---|
itemid | WG Note - No longer being actively developed |