Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to use bootstrap tooltip? [closed]

I have used Bootstrap but the tooltip is not working

<a href="#" data-original-tittle="test" 
            data-placement="right"
            rel="tooltip"
            target=" _blank"> hover me 
</a>

Or do I need to use jQuery?

like image 977
M.R Avatar asked May 09 '13 12:05

M.R


People also ask

How do I make my tooltip always visible?

Single element To make an element display its tooltip permanently, we use its showTooltipOn property. To make tooltip always be shown, set it to "always" .

How do I show tooltip in bootstrap?

How To Create a Tooltip. To create a tooltip, add the data-toggle="tooltip" attribute to an element. Note: Tooltips must be initialized with jQuery: select the specified element and call the tooltip() method.

How do I change the tooltip position in bootstrap?

How to position the tooltip - auto | top | bottom | left | right. When auto is specified, it will dynamically reorient the tooltip. When a function is used to determine the placement, it is called with the tooltip DOM node as its first argument and the triggering element DOM node as its second.


1 Answers

Try to add tooltip like

<script type="text/javascript">
    $(function(){
       $('[rel="tooltip"]').tooltip();
    });
</script>

or you can directly select as

$('a').tooltip();

or try with it

<a href="#" data-toggle="tooltip"
data-original-title="Tooltip on right">hover me</a>

and your script like

$(function() {
    $('a').tooltip({placement: 'right'});
});

MY ULTIMATE FIDDLE finally HERE

like image 93
Gautam3164 Avatar answered Sep 23 '22 19:09

Gautam3164