Re: DI element [Re: html 5 and accessibility issue]

On 7/3/07, Henri Sivonen <hsivonen@iki.fi> wrote:
> If HTML5 had <di>, the parsing algorithm (and, by consequence, off-
> the-shelf parsing libraries) would have to add it implicitly or else
> the document tree would still be able to contain the implicitly
> grouped case and which would still require app-level handling by the
> desperate microformat hacker. But if HTML5 did that, the parsing
> algorithm would not be suitable for existing content in the browser
> case as Selectors would match differently all of a sudden.

No, I'd want it to work just the same as <tbody> (there's no implicit
"tbody" in the DOM/API stuff is there?) If the author puts it in, it's
in the document. If the author omits it, it is not in the document.
Responsibility rests with the author to use it (or not).

Creators of parsers can then say "requires <di>" if they wish... this
is an additional conformance requirement for that parser above and
beyond HTML. Authors can comply or not, as they wish. If they don't,
they won't conform with that parser.

Here's an example with tables again:
http://kryogenix.org/code/browser/sorttable/
I'd recommend reading it, but here are the key points.
This script sorts tables, so you can grab it, add it to your site,
starting using it. Busy authors love stuff like this (when coded
well!) To make it work you need to use <thead> in your tables. HTML
doesn't require this. The sorttable script does though. Further, to
prevent "totals" from being sorted you need to use <tfoot>. Not "we'll
assume in some cases the last <tr> might be a footer" - it is "use
<tfoot>".

These are the kind of situations where this markup really shines, and
some authors may be motivated to make use of it because some script
developer has given them a good reason to do so.

Received on Tuesday, 3 July 2007 11:44:58 UTC