Revision: 19213
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at October 18, 2009 07:02 by teedy
Initial Code
$(function() { $('.cirroHover').each(function(){ var txt = $(this).attr('title'); $(this).append('<em class="" style="position:absolute;background:#000;color:#fff">'+txt+'</em>'); $(this).find('em').hide(); }); $('.cirroHover').hover(function(){ var x = $(this).offset().left; var y = $(this).offset().top; $(this).find('em').css({top: ((y*1)+12)+'px', left: x+'px'}).show('fast'); return false; }); $('.cirroHover').mouseleave(function(){ $(this).find('em').hide('fast'); }); });
Initial URL
http://cirrostratusco.com
Initial Description
A simple jQuery-powered hover based on the element's title
Initial Title
Cirrostratus Hover
Initial Tags
javascript, jquery, web, design
Initial Language
jQuery