2

I have added comment button in my table.When I hover it tooltip will be displayed.
How to change style of tooltips? Can anyone help me?

.tooltip-arrow,
.cancelComments + .tooltip > .tooltip-inner {background-color: #f00;}

https://jsfiddle.net/5h1ybdp1/3/

I tried using popover also but popover is not displaying.

user7397787
  • 1,410
  • 7
  • 28
  • 42
  • Possible duplicate of http://stackoverflow.com/questions/15383440/styling-the-arrow-on-bootstrap-tooltips/38279489#38279489 and http://stackoverflow.com/questions/17642447/change-bootstrap-tooltip-color – Sagar May 08 '17 at 07:35

4 Answers4

7

Here are simple example

HTML

  <a href="#" data-toggle="tooltip" data-placement="bottom"
       title="" data-original-title="Tooltip on bottom"
       class="red-tooltip">Tooltip on bottom</a>

CSS

.red-tooltip + .tooltip > .tooltip-inner {background-color: #f00;}
.red-tooltip + .tooltip > .tooltip-arrow { border-bottom-color:#f00; }

http://jsfiddle.net/technotarek/2htZe/

Here is working fiddle with your code, the problem you didnt reference bootstrap.js!

https://jsfiddle.net/5h1ybdp1/7/

Miomir Dancevic
  • 6,726
  • 15
  • 74
  • 142
  • Have you double checked if you referenced your bootstrap files in a proper way? Because I think this code should work. Also, maybe a link to [this post](http://stackoverflow.com/questions/17642447/change-bootstrap-tooltip-color) could clear out things for you. – kevin b. May 08 '17 at 07:14
0

Well, you supposed to write a script in order to generate a tool tip as follows and you haven't include bootstrap.min.js, jqueryand bootstrap.min.js including order is also important. This will resolve your issue here is your updated fiddle https://jsfiddle.net/8q88jrtr/6/

$(document).ready(function(){
    $("i").tooltip();
});
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
this.girish
  • 1,296
  • 14
  • 17
0
<!-- CSS -->
<style>
a i{margin:50px 0 0 50px;}
#my-tooltip + .tooltip > .tooltip-inner {background-color:#EF5438;}
#my-tooltip + .tooltip > .tooltip-arrow {border-top:5px solid #EF5438;}
</style>
<!-- HTML -->
<a href="#" data-toggle="tooltip" data-placement="top" title="Ur 
Facebook" id="my-tooltip"><i class="fa fa-facebook"></i></a>
Makyen
  • 31,849
  • 12
  • 86
  • 121
sam
  • 11
0
Change Markup adding title and content in bootstrap-3  tool-tip

//add this script in footer or header after bootstrap js, css and jquery resources

    <script>
            $(document).ready(function () {
                //tooltip added on attribute "data-toggle"
                $('[data-toggle="tooltip"]').tooltip();
                $(".tooltipControl").popover({ trigger: "hover" });
</script>

Html

<a links tooltipControl" data-content="No Detail" data-placement="right" data-original-title="Title">See tooltip Here</a>
Billu
  • 2,733
  • 26
  • 47