XFN short for XHTML Friends Network was the first microformat and it remains perhaps the easiest of all microformats to implement. It is basically used by webmasters to indicate real world relationships with the people they mention in their blogroll/links.
Now if I were to link to a friend I would enter it into my blogroll as so
<a href="http://some-site.com">Some Body</a>
In order to make this a XFN microformat, I would simplay add the “rel” attribute to the link, with a description of our relationship
<a href="http://some-site.com" rel="friend">Some Body</a>
You can also add more information in the “rel” attribute, if for example you have met the person:
<a href="http://some-site.com" rel="friend met">Some Body</a>
Seems pretty simple right?
Here are all the values I know of that you can add in the “rel” attribute
- me : If you are linking to another website of yours
<a href="http://some-site.com" rel="me">Some Body</a>
- Friendship Type - This can be ” or any one of the following
- contact
- acquaintance
- friend
- Physical Type - This can be ” or any one of the following
- met :If you have met this person or not
- Professional Type - This can be ”, any one of the following, or all
- co-worker
- colleague
- Geographical Type - This can be ” or any one of the following
- co-resident
- neighbour
- Family Type - This can be ” or any one of the following
- child
- parent
- sibling
- spouse
- kin
- Romantic Type - This can be ”, any one of the following, or all
- muse
- crush
- date
- sweetheart
You can also style each of the above classes differently to make a link appear different for a family member or a work colleague.
You can read more about XFN at these sites:
GMPG.org
XFN on wiki