I had an opportunity to complete my first foray into microformats today: my contact data is now available as an hCard.
If you haven’t heard of microformats before, they’re simply a step in the direction of the semantic web where human-readable content has associated data that is meaningful to machines as well. The easiest way to get an idea of what I’m talking about is to try it. Check out my hCard, then use x2v to parse that same web page. All that’s happening here is a small script (specifically an “extensible stylesheet transformation) is taking that page and converting the hCard bit into a vCard. vCards are the standard file format for contact for PIMs and email packages.
hCard is just one example, although the one I find most useful. At this time, there are nine completed specifications for microformats at the microformats wiki and ten more well into development. Some are simple, such as rel-license which provides a computer-discoverable method of linking to licenses like Creative Commons. Others, like xfn, are a lot larger and in this case worthy of their own site. Still more like AHAH aren’t getting nearly the press they deserve.
So where did microformats come from? A number of web services had some itches they needed to scratch, but they needed the solutions to their problems to be standards-compliant and here now, note at some undefined future date when the W3C got around to it. Here are a few examples:
- Technorati added the ability to tag posts they track. Hence rel-tag
- Creative Commons licenses needed be machine-discoverable, so we got rel-license as above
- Spam Blogs and comment spamming started being a real problem, so the major search players got together and agreed on rel-nofollow
In general, microformats make life much easier for people who need to index information; search engines in particular. As an example, the hReview format for marking up any kind of review would mesh nicely with local search and tools that help you discover books based on relationships. You can easily add them by hand to your code. If you’re blogging with WordPress or MT, you can use Structured Blogging plug ins to add easy support for the majority of published formats. The benefit to the developer is that your content immediately becomes more findable, and easier to reuse in ways you might not have expected. Think Google Map of your restaurant reviews or geo-coded picture posts, for example.
Want to try your hand at coding microformats? Your best first stop is “Practical Microformats with hCard” over at the geeky advent calendar 24 ways.