W3C home > Mailing lists > Public > public-html@w3.org > April 2008

Re: 3.12.8 dfn automatic cross-referencing

From: Ian Hickson <ian@hixie.ch>
Date: Wed, 23 Apr 2008 00:46:53 +0000 (UTC)
To: Ben Boyle <benjamins.boyle@gmail.com>
Cc: HTML WG <public-html@w3.org>
Message-ID: <Pine.LNX.4.62.0804230014070.25764@hixie.dreamhostps.com>

On Wed, 1 Aug 2007, Ben Boyle wrote:
> 
> There is an algorithm proposed for automatically cross-referencing dfn 
> from other elements: http://dev.w3.org/html5/spec/Overview.html#dfn

I've now removed this algorithm in favour of <a href="">. For more details 
on the thinking behind that, see this e-mail:

   http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2008-April/014470.html

(Basically, it's too complicated for what it gives us.)


> I would find this useful, however it will not work with the typical way 
> I handle abbreviations. I'm not alone, I went searching for some more 
> information and found this interesting thread that discusses many use 
> cases and alternative solutions for abbreviations in HTML: 
> http://www.webaim.org/discussion/mail_thread.php?thread=3359
> 
> I have altered the example from the spec to match how I would currently 
> author the abbreviation. (Habits can be changed, if there is a 
> compelling reason to do so.)
> 
> <p>The <dfn>Garage Door Opener (<abbr>GDO</abbr>)</dfn>
> is a device that allows off-world teams to open the iris.</p>
> <!-- ... later in the document: -->
> <p>Teal'c activated his <abbr>GDO</abbr> and so Hammond ordered the iris 
> to be opened.</p>
>
> Key differences: I would expand the acronym in the surrounding text (not 
> the title attribute). I would prefer to surround the expansion and 
> abbreviation with the <dfn> tags (that may just be a quirk of how I 
> interpret the semantics, but it is the same context as dfn@title). I 
> would not want to repeat the expansion again (not even in title 
> attributes) within the same document.

The term being defined is "Garage Door Opener", so I'd say the right 
markup is:

   <p>The <dfn>Garage Door Opener</dfn> (GDO) is...

...but I agree that had we kept the cross-referencing feature, this still 
wouldn't work.


> SUGGESTION 2:
> Another option I'd support (which has been proposed before) would be
> using an idref relationship.
> 
> <p>The <dfn id="GDO">Garage Door Opener (<abbr>GDO</abbr>)</dfn>
> is a device that allows off-world teams to open the iris.</p>
> <!-- ... later in the document: -->
> <p>Teal'c activated his <abbr idref="GDO">GDO</abbr>
> and so Hammond ordered the iris to be opened.</p>
> 
> I've used @idref as an abstract name to illustrate the concept. I would 
> not mind @for if that isn't too much overloading.

That's close to what we currently have, which is:

   <p>The <dfn id="GDO">Garage Door Opener</dfn> (GDO) is a device that 
   allows off-world teams to open the iris.</p>
   <!-- ... later in the document: -->
   <p>Teal'c activated his <a href="#GDO">GDO</a> and so Hammond ordered 
   the iris to be opened.</p>


> If we're feeling courageous, some guidance on which abbreviations are 
> worth the markup would be great.

Right now the rule is basically "use <abbr> if you're giving an 
expansion", but this may change, as people seem to want to mark up 
abbreviations even without expansions. I'm not sure what advice to give, 
though. Any suggestions? As far as I can tell it's:

 * Definitely mark up any abbreviation you want to give an expansion for.

 * Mark up abbreviations and give expansions for them if they're terms 
   that your readers may not know.

 * Mark up other abbreviations if you need them semantically annotated 
   (e.g. because you want to style abbreviations).

Would that be enough?

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Wednesday, 23 April 2008 00:47:29 UTC

This archive was generated by hypermail 2.3.1 : Monday, 29 September 2014 09:38:54 UTC