David Cramer's Blog

Python, Django, and Scale.

HTML Tooltips

So I finally took the time to rework my tooltips script which is in use on sites like WoW Guru. I originally created it as an alternative to using overlib and other quite large (bloated?) libraries as I didn’t need 90% of what they do.

The tooltip library is very simple, as it currently has one option, which let’s you adjust the horizontal alignment with the source (wherever the tooltip is originating from). To use the library it’s as simple as including the javascript on your page (most likely in the header) and calling onmouseover=”showTip(event, ‘Text’);” on an element.

If this is of use to you, have at it, if you’d like to see anything changed or added let me know. You can download the javascript tooltips source here.

Comments