Live preview (hover over the navigation): http://www.monikercreative.com/monikerguest/test.php
I'm having a problem getting the tooltip to move next to each nav list item...I can move the static tooltip placement around and I've tried using offset and jobj width, but it doesn't work well since the nav items do not get progressively wider, and width of the window shouldn't be taken into account. Is there any way I can define the distance to offset it with just by unique list item classes? For example, li.first is offset 0, li.second is offset 50px, etc. Or another way that this could be accomplished? Here's the code: function prepare(jObj, options) { var $tooltip = $(options.tooltip); var element = jObj[0]; var offset = jObj.offset(); var left = 120; var top = offset.top-25; if(options.onShow){ options.onShow.call(this, {target:jObj}); } if($(window).width()-offset.left <= $tooltip.width()) { left = offset.left - $tooltip.width(); } else{ left += 5; } $tooltip.css({position:'absolute', top:top+'px', left:left+'px'}); };