HTML and CSS Reference
Listing 1.5. html5-microdata.html—Microdata in action
The HTML5 specification also defines a DOM API that you can use to dynamically re-
in table 1.3 .
Table 1.3. The microdata DOM API
Gets all elements that are top-level microdata items (elements with an item-
scope attribute). You can use the types argument to filter by one or more item-
type attribute values.
Gets all item properties (those elements with an itemprop attribute) for a given
microdata item (element).
element.itemValue [= value]
Gets or sets the value of an item property.
Using microdata is an excellent way to improve how your application (or document) looks
in search results. In the next section, you'll learn how you can use CSS3 to make your ap-
plication visually stunning with the new styles and effects it has to offer.