在Bootstrap 3中将换行符添加到工具提示中 [英] Add line break to tooltip in Bootstrap 3
本文介绍了在Bootstrap 3中将换行符添加到工具提示中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用Bootstrap 3,并向我的div中添加了一个工具提示.我试过使用< br> \ n和
创建新行. Bootstrap阻止我会出现问题吗?
I am using Bootstrap 3 and added a tooltip to my div. I've tried using < br > \n and 
 to create the new line. Would it be a problem with the Bootstrap stopping me?
<div class="content show-tooltip" data-placement="top"
data-original-title="1st line of text <br> 2nd line of text">
推荐答案
您需要在标记中添加data-html="true"
.
<div class="content show-tooltip" data-html="true" data-placement="top"
title="1st line of text <br> 2nd line of text">
正在运行的演示: http://www.bootply.com/83099
这篇关于在Bootstrap 3中将换行符添加到工具提示中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文