This is an archive of an inactive wiki and cannot be modified.

hGRDDL is a proposal to use a GRDDL-like approach to transform HTML+microformat to HTML+RDFa. This page describes an example of hGRDDL.


Consider an HTML page with an hCard. The example used here is a combination of examples from

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="" xml:lang="en" lang="en">
<head profile="">

<address class="vcard"> 
 <img src="myphoto.jpg" class="photo" alt="my photo" />
 <a class="url fn" href="">Jane Smith</a>.
 <a class="email" href="">email</a>

 <div class="adr">
   <div class="street-address">665 3rd St.</div>
   <div class="extended-address">Suite 207</div>
   <span class="locality">San Francisco</span>,
   <span class="region">CA</span>
   <span class="postal-code">94107</span>
   <div class="country-name">U.S.A.</div>




An hGRDDL-RDFa-aware agent should be able to:

The hGRDDL transform for hCard specifically does the following:

Resulting HTML+RDFa

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="" xml:lang="en" lang="en">

<address class="vcard"
 <img src="myphoto.jpg" class="photo" alt="my photo" 
      rel="vcard:photograph" />
 <a class="url fn" href=""
    rel="foaf:homepage" property="vcard:fn">Jane Smith</a>.
 <a class="email" href=""

 <div class="adr" rel="vcard:adr">
   <div class="street-address" property="vcard:street-address">665 3rd St.</div>
   <div class="extended-address" property="vcard:extended-address">Suite 207</div>
   <span class="locality" property="vcard:locality">San Francisco</span>,
   <span class="region" property="vcard:region">CA</span>
   <span class="postal-code" property="vcard:postcal-code">94107</span>
   <div class="country-name" property="vcard:country-name">U.S.A.</div>



Getting it Running

Get the hGRDDL-enabled, RDFa-based, N3 extractor bookmarklet: bookmarklets

Visit the hcard example: Sample HTML+hcard file

Click on the N3 extractor.

You can also try the RDFa highlighter.