Towards Copy and Paste eRDF

Some recent discussion on the W3C’s RDF-in-XHTML list has got me thinking about how to enhance Embedded RDF to enable copy-and-paste metadata. Being able to copy some markup from one document to another is a key requirement of the RDF-in-XHTML taskforce. One strong use case is for embedded Creative Commons licences. Here the Creative Commons people would like to be able to generate a snippet of XHTML to be copied into the user’s document without them having to change markup in multiple places. Currently eRDF requires at least three changes to the XHTML document to enable the embedding:

  1. Addition of profile attribute on head
  2. Schema prefix declarations in head
  3. Embedded markup in body

I think there’s a small change that could be made to the eRDF parsing rules to eliminate number two on that list. Currently schema prefixes are declared in link tags in the head of the document:

<link rel="schema.foaf" href="http://xmlns.com/foaf/0.1/" />

My idea is to relax the constraint that the schema declaration must be in a link tag and allow it to appear anywhere in the document for any element that has a rel attribute. So this would allow:

The current specification already allows duplicate schema prefixes to be declared:

The order in which the schemas are declared is not significant. Where two identical schema prefixes are declared the first takes precedence. Any subsequent declarations are ignored.

It would require the prefix name “schema” to be reserved throughout the document but I don’t think that would cause any serious problems.

With this change it would be possible to write licence links like this:

<div>
  This work is licensed under a
  Creative Commons
  
     Attribution 2.0 England & Wales License
  
</div>

Thoughts and comments welcome as always.

About Ian Davis

British entrepreneur and CEO of Kasabi. Primary interests are open data, the semantic web and decentralization.
This entry was posted in Uncategorized and tagged , , . Bookmark the permalink.

2 Responses to Towards Copy and Paste eRDF

  1. Benjamin Nowack says:

    Yay, that’s a great extension. :)

  2. Jim White says:

    +1!!!I was just going to make that suggestion myself.There are many situations where the HTML author can easily control the body content but not the head.I’m going to use eRDF in my wiki publishing tool based on JSPWiki. How to support schemas that weren’t preconfigured was the only problem I encountered.With this fix, eRDF will be perfect! Well, apart from types… ;-)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s