JQuery: Hover to show/hide individual object
Posted
by noe ruiz
on Stack Overflow
See other posts from Stack Overflow
or by noe ruiz
Published on 2010-05-10T21:27:38Z
Indexed on
2010/05/10
21:34 UTC
Read the original article
Hit count: 182
jQuery
Basically I need to hover over an anchor to display the "data-meta" div. Works just fine but when there's multiple td and divs, one hover displays all of them. My question is how can I show/hide them individually? Code snippets below.
<td>
<a href="#">Item</a>
<div class="data-meta">
<a href="#">Edit</a> | <a href="#">Disable</a> | <a href="#">Delete</a>
</div>
$(document).ready(function(){
$("td").hover(
function () {
$('.data-meta').show();
},
function () {
$('.data-meta').hide();
});
});
© Stack Overflow or respective owner