RDFa is a syntax for expressing this structured data in XHTML. The rendered, hypertext data of XHTML is reused by the RDFa markup, so that publishers don't repeat themselves. The underlying abstract representation is RDF, which lets publishers build their own vocabulary, extend others, and evolve their vocabulary with maximal interoperability over time. The expressed structure is closely tied to the data, so that rendered data can be copied and pasted along with its relevant structure. (RDFa Primer 1.0 Embedding RDF in XHTML, retrieved 15:17, 23 April 2007 (MEST)).
Current web pages, written in HTML, contain significant inherent structured data. When publishers can express this data more completely, and when tools can read it, a new world of user functionality becomes available, letting users transfer structured data between applications and web sites. An event on a web page can be directly imported into a user's desktop calendar. A license on a document can be detected so that the user is informed of his rights automatically. A photo's creator, camera setting information, resolution, and topic can be published as easily as the original photo itself, enabling structured search and sharing. (RDFa Syntax, retrieved 15:17, 23 April 2007 (MEST))
This short example taken from the Primer shows that RDF data can be embedded within "rel" and "property" attributes.
- The clueless HTML version
<html> <head><title>Jo's Blog</title></head> <body> ... <p> I'm giving a talk at the XTech Conference about web widgets, on May 8th at 10am. </p> ... <p class="contactinfo"> My name is Jo Smith. I'm a distinguished web engineer at <a href="http://example.org"> Example.org </a>. You can contact me <a href="mailto:email@example.com"> via email </a>. </p> ... </body> </html>
- The RDFa version
As you can see it refers to two well known XML namespaces, i.e. ICAL and VCARD.
<html xmlns:cal="http://www.w3.org/2002/12/cal/ical#" xmlns:contact="http://www.w3.org/2001/vcard-rdf/3.0#"> ... <p class="cal:Vevent" about="#xtech_conference_talk"> I'm giving <span property="cal:summary"> a talk at the XTech Conference about web widgets </span>, on <span property="cal:dtstart" content="20070508T1000+0200"> May 8th at 10am </span>. </p> ... <p class="contactinfo" about="http://example.org/staff/jo"> My name is <span property="contact:fn"> Jo Smith </span>. I'm a <span property="contact:title"> distinguished web engineer </span> at <a rel="contact:org" href="http://example.org"> Example.org </a>. You can contact me <a rel="contact:email" href="mailto:firstname.lastname@example.org"> via email </a>. </p> ...
- The extracted RDF triplet
A RDF parser now could extract for instance the following information from this file:
<http://jo-blog.example.org/blog/?p=123#xtech_conference_talk> rdf:type cal:Vevent; cal:summary "a talk at the XTech Conference about web widgets"^^XMLLiteral; cal:dtstart "20070508T1000+0200" .
- See also: RDFa Implementations (at rdfa.info). Lists various libraries and filters.
3.1 On line
- Zitgist dataviewer (a user friendly Semantic Web data viewer). Handles RDF and XHTML+RDFa.
3.2 Browser extensions
- Operator. (Firefox extension) Quote: "Operator leverages microformats and other semantic data that are already available on many web pages to provide new ways to interact with web services."
- RDFA2XSLT (RDFa to RDF+XML filter)
- Bodies (organizations)
- RDFa (Wikipedia)
- The future of RDFa, bobdc.blog, by Bob Ducharme, Feb 2008.
- Bridging the Clickable and Semantic Webs with RDFa, ERCIM News, by Ben Adida, 2008 ?
- Introducing RDFa, By Bob DuCharme, XML.com, February 14, 2007
- RDFa (ESW Wiki at W3C).
- RDFa in a nutshell by fabien gandon, INRIA.