Keep Twitter Bootstrap Tooltip open on mouseleave

John picture John · Mar 26, 2013 · Viewed 18.4k times · Source

For a particular case and element I need to show Bootstrap Tooltip by default (once the page is loaded) an always keep it open (even on mouseover and mouseout).

That's the code I use to open tooltip by default on the element:

$('#myelement').tooltip('show');

Now I'm not sure how to prevent/disable the default action of tooltip on mouseover & mouseout. Any idea?

Thanks in advance!

Answer

John picture John · Mar 26, 2013

Solution found. Manual Trigger does the trick - here is the updated code:

$('.taskTooltip').tooltip({trigger: 'manual'}).tooltip('show');