Microdata: HTML5's Best-Kept Secret
Microformat syntax example:
<div itemscope itemtype="http://data-vocabulary.org/Organization">
<h1 itemprop="name">Hendershot's Coffee Bar</h1>
<p itemprop="address" itemscope itemtype="http://data-vocabulary.org/Address">
<span itemprop="street-address">1560 Oglethorpe Ave</span>,
<span itemprop="locality">Athens</span>,
<span itemprop="region">GA</span>.
</p>
</div>
So how does Microdata fit with Microformats and RDFa? Well, the WHAT-WG, which helps to develop the HTML5 spec, decided the flame wars provoked by the debate over whether to use Microformats or RDFa lacked sufficient vehemence, so they added a third definition of their own.
Actually, the reasoning seems to have been something like this: Microformats are a really good idea, but essentially a hack. Because Microformats rely only on the class and rel attributes, writing parsers to read them is complicated.
At the same time, RDFa was designed to work with the now-defunct XHTML 2.0 spec. Although RDFa is being ported to work with HTML5, it can be overly complex for many use cases.
Comments
Post new comment