[development] jquery 1.0 release imminent

Morbus Iff morbus at disobey.com
Tue Aug 22 11:12:10 UTC 2006

> I mentioned that I started playing with jQuery, when I put the finishing 
> touches on my hovertips module I planned to contribute it (for 4.7.x):
> http://dave-cohen.com/node/1186

I never did like this particular implementation. There are four types:

  * Inside spans: <p>Whee! <span>you're hovering!</span></p>, which makes
    it really ugly for screen readers or just general DOM goodness.

  * External divs, like you: <p>Whee</p> <div>you're hovering!</div>
    Also can be ugly depending on where you place all the divs (at the
    very end of the document? is that cleanly possible?). Would require
    you to match up IDs in two different places though.

  * Alt/title hovers - based on the value of the title text. <p title=
    "you're hovering!">Whee!</p>. This one's bad because you can't use
    HTML in your tip very cleanly.

  * JS events, such like <p onmouseover="tooltip_on('you're hovering!')"
    onmouseout="tooltip_off()">Whee!</p>. I tend to like this one (and
    implemented it in my game.module, not via jQuery though) the most
    because it a) doesn't pollute the DOM, b) don't harm screen readers,
    c) allows HTML, d) keeps everything in one place, e) doesn't require
    bookkeeping (which ID goes with this element?).


[1] http://cvs.drupal.org/viewcvs/drupal/

Morbus Iff ( omnia mutantur, nihil interit )
Technical: http://www.oreillynet.com/pub/au/779
Culture: http://www.disobey.com/ and http://www.gamegrene.com/
icq: 2927491 / aim: akaMorbus / yahoo: morbus_iff / jabber.org: morbus

More information about the development mailing list