I’m trying to implement a very simple javascript. I’m building some kind of a tooltip (a hidden <div> within the link) for when a link is hovered.
So the thing is I have several links that have their own tooltip, with the code shown below the tooltips are correctly showing and hiding but the thing is I only want to show the tooltip related to that link only, not all of them.
I think the good way to solve this is having one javascript function that only show the tooltip for that specific link and not having a function for each one of them.
Thanks in advance for any help, I hope I have explained my issue in a way you can understand.
$(function() {
$('.toolshoot').hover(function() {
$('.toolbox').show();
},
function () {
$('.toolbox').hide();
}
);
});
I guess this would work:
I’m searching for
.toolboxinside of the element being hovered.Next time please post a code sample with it’s markup.