Benjamin Hawkes-Lewis:

If you want to to use RDF in an HTML context, look to eRDF

eRDF is an interesting experiment, but not particularly practical.

Probably the biggest practical problem with it is the use of the id attribute to indicate that (by the attribute's mere presence) an element is the subject of any data found in descendant elements. This makes it difficult to add eRDF to existing documents which are usually already sprinkled liberally with id attributes.

For example, if you have a side bar on a page and want to use it to provide some supplementary information about the main body of text, you might expect something like this to work:

        <div id="sidebar">
          <h2>About this page</h2>
          <div class="dc-title">Foo bar</div>
          <div class="dc-creator">Joe Bloggs</div>
        </div>

However, this actually says that the title of <#sidebar> (i.e. not of the whole page) is "Foo bar", and that <#sidebar> was created by Joe Bloggs. Yes, you can rejig things a bit, make your sidebar use a class instead of an id, but adding eRDF to existing pages a pain - especially if they're not simple static pages, and you would need to go through thousands of lines of server side code to find all those id attributes.

If you're writing an eRDF page from the ground up, this will probably not bother you as much.

The other serious concern is that any information you wish to state about a resource which is not a physical anchor on the current page needs to be made within a link. So if Alice wants to link to Bob's page and mention the title of Bob's page, and when it was last updated, she would need to write something along the lines of:

        <a href="http://bob.example.net";>
          <span class="dc-creator">Bob</span>'s blog
          <span class="dc-title">Groovin' with Bob</span>
          was updated <span class="dc-date" title="20080629">today</span>
        </a>

whereas without eRDF, most normal people would probably only want to link the blog's title, not the whole phrase. This gets pretty awkward if you want to say substantial amounts of information about an off- page resource. (It's possible to work around it by using an id attribute somewhere, saying the information about the id attribute instead of saying it about the link, and then using owl:sameAs to say that the link and the id attribute are the same thing. But that is a hack.)

Final annoyance: varying between dots and hyphens to separate the QName prefix and suffix, seemingly at random.

Yes, it's quite impressive what they managed to achieve, bringing most of the RDF stack to HTML 4, without adding any new attributes or elements. Yet when it comes to implementing it on real life pages, it's annoying.

RDFa is a much nicer solution to work with.

--
Toby A Inkster
<mailto:[EMAIL PROTECTED]>
<http://tobyinkster.co.uk>



_______________________________________________
microformats-discuss mailing list
microformats-discuss@microformats.org
http://microformats.org/mailman/listinfo/microformats-discuss

Reply via email to