I am trying to show a bootstrap tooltip on hover over an image. I have a text in that tooltip that i need to make it bold.
I tried this from the mentioned source, but didnt work form me..
<button class="infoTipsBox" type ="button" data-toggle="tooltip" data-placement="right"data-original-title='<b>big tooltip</b>'>
</button>
Js:
$(function () {
$('[data-toggle="tooltip"]').tooltip();
});
What im i doing wrong??
In the above text in the title
attribute, I am trying to make the "bootstrap tooltip" in bold font and rest in normal font. How can i achieve this?
As you can see in Bootstrap' official documnetation for tooltip
Name | Type | default | Description
----------------------------------------------------------------------------
html | boolean | false | Insert html into the tooltip.
If false, jquery's text method
will be used to insert content
into the dom. Use text if you're
worried about XSS attacks.
so, add data-html="true"
to your tooltip and this will enable HTML in your tooltip
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With