Microformat Shiv

A light weight cross browser JavaScript Microformats parser

XFN Example

Below is an example of the Microformat Shiv parsing a XFN. This microformat is a simple way to represent human relationships using hyperlinks. You can check the compliance of the Microformat Shiv to the XFN standard on the microformats test suite.

Code to parse the XFN

var domNode = document.getElementById('xfn-example');
var jsonObject = navigator.microformats.get('XFN', domNode);
   
alert(JSON.stringify(jsonObject));