Oliver Brown introduced me to microformats a while ago, the Ryan Eby got excited about them, then COinS-PMH showed how useful they could be for libraries, but I still haven’t done anything with them myself (other than beg Peter Binkley to release his COinS-PMH WordPress Plugin).
What are microformats? Garrett Dimon explains the theory:
When writing markup against deadlines and priorities, it’s easy to forget that somebody else will eventually have to maintain it. Conveniently, some of the central ideas behind microformats revolve around the fact that they are designed for humans first and created with simplicity in mind. This means you’ll have markup that is easy to understand and maintain for everyone, including:
- The engineer integrating your code next week
- You updating your code next month
- The new guy taking over your job when you get promoted next year
Basically, microformats suggest the use of common class names for various XHTML elements. As it turns out, the hCard microformat is a convenient way of representing the data from vCards in XHTML. The convenience is by design, of course. Here’s an example:
<div class=“vcard”><br /> <a class=“url fn” href=“http://maisonbisson.com/”>Casey Bisson</a><br /> <div class=“org”>MaisonBisson</div><br /> </div>
By standardizing the class names for this content, it’s easier to share and maintain stylesheets, re-use content, and read the content programatically. Perhaps most importantly, it offers valuable tips to search engines crawling your site about what the data is, making it more findable.
The principles of microformats are such:
- solve a specific problem
- design for humans first, machines second
- reuse building blocks from widely adopted standards
- modularity / embeddability
- enable and encourage decentralized and distributed development, content, services