Riot Zeast Captain Riot Zeast Captain - 7 months ago 13
HTML Question

How to change mouse click to mouse hover?

Here is the jsfiddle link in which I got the code for the animated tooltips, but the problem is that on

click
only they are working, I want that to be animate when I
hover
the mouse on it.

Answer

JSFiddle.

Use mouse events mouseenter and mouseleave.

$('.popover-example li a').mouseenter(function() {
   $(this).trigger("click");
}).mouseleave(function() {
   $(this).trigger("click");
})