HTML and CSS Reference
In-Depth Information
Microdata and Microformats
As mentioned earlier, overlapping features can be described by both microdata and microformats, as well as arbitrary
features using RDFa. Microformats can also be used simultaneously with (X)HTML5 microdata. For example, hCard
can be written together with microdata, as shown in Listing 7-89.
Listing 7-89. Combining hCard with Microdata
<dl class="vcard" itemscope itemtype=" " >
<dt class="fn" itemprop="name"><a href=""
itemprop="url">John Smith</a></dt>
<dd class="title" itemprop="title">Photographer</dd>
<dd class="adr" itemprop="address" itemscope
itemtype=" " ><span class="locality"
itemprop="locality">Memphis</span>, <abbr title="Tennessee" class="region"
<span class="postal-code" itemprop="postal-code">38145</span></dd>
Dublin Core and vCard in RDF
The flexibility of the Resource Description Framework makes it simple to use more than one kind of metadata from
external namespaces at the same time. Consequently, rich semantics can be added to documents from a variety of
vocabularies simultaneously (Listing 7-90).
Listing 7-90. Dublin Core and vCard in RDF
<?xml:namespace ns=" " prefix="RDF" ?>
<?xml:namespace ns=" " prefix="DC" ?>
<?xml:namespace ns=" " prefix="CARD" ?>
<RDF:Description RDF:HREF="http://uri-of-Document-1">
<DC:Creator RDF:HREF="#Creator_001"/>
<RDF:Description ID="Creator_001">
<CARD:Name>John Smith<CARD:Name>
<CARD:Affiliation>ABC Ltd.<CARD:Affiliation>
Dublin Core, vCard, and Math-Net
The introduction of a person on a brochure-style home page can be described in many ways. One of them is the
combination of Dublin Core and vCard. Indexing and processing such data can be enhanced by providing them in
RDF. Listing 7-91 shows an example.
Search WWH ::

Custom Search