jquery - How do I add blank lines into a Bootstrap Tooltip -
i working on website has different features person can order. put bootstrap glyphicon next features , when user rolls on glyphicon tooltip show included in features. having trouble introducing blank lines tooltip. i've tried \n
, 
 (with pre-wrap command in css) here portion of code cooresponding tooltip.
<br/>2 printed sheets <a href="#" data-toggle = "tooltip" title = "one printed sheet can include 
1 8 x 10 
2 5 x 7 
2 4 x 6 
4 3.5 x 5 
9 wallet photos"> <span style = "color:white" class="glyphicon glyphicon-question-sign white"></span> </a>
i'm using following jquery command:
<script> $(document).ready(function(){ $('[data-toggle="tooltip"]').tooltip(); }); </script>
how can put blank lines 
 is. worth noting before added in jquery section blank lines did work properly, when added in jquery section line breaks removed.
set html true , use <br>
in title attribute, or can set data attribute data-html="true"
$(document).ready(function(){ $('[data-toggle="tooltip"]').tooltip({ html:"true" }); });
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"/> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js"></script> <h1>tooltip below</h1> <a href="#" data-toggle = "tooltip" data-placement = "down" title="one printed sheet can include 
<br></a>1 8 x 10 
<br></a>2 5 x 7 
<br></a>2 4 x 6 
<br></a>4 3.5 x 5 
<br></a>9 wallet photos"> <span style = "color:white" class="glyphicon glyphicon-question-sign white"></span>tooltip </a>
Comments
Post a Comment