![](/img/trans.png)
[英]Popup Twitter Bootstrap Popover not showing at correct place after image load
[英]Popover is not showing image?
Onmouse懸停,popover只顯示標題而不是圖像
代碼:
<script type="text/javascript">
$(document).ready(function(){
var img ='<img src="/assets/Excel_1.png">';
$("#blob").popover({ title: 'Format for Excel sheet', content: img , trigger:'hover' });
});
</script>
身體:
<i href="#" id="blob" class="icon-info-sign" rel="popover" style="margin-top: 300px"> </i>
但沒有顯示圖像.....
謝謝
得到了這個簡單問題的解決方案......
$("#blob_1").popover({ title: 'Format for Excel sheet', content: img , trigger:'hover',html: true });
只是這種改變使得需要成為可能
謝謝..
請查看本教程並確保正確輸入指定的圖像網址:
http://www.w3resource.com/twitter-bootstrap/popover-tutorial.php
試試這個: http : //jsbin.com/iducul/1/edit
Html是:
<a href="#" id="example" class="btn btn-success" rel="popover">hover for popover</a>
jQuery是:
$(function (){
var img = '<img src="https://si0.twimg.com/a/1339639284/images/three_circles/twitter-bird-white-on-blue.png" />';
$("#example").popover({title: 'Twitter Bootstrap Popover', content:img});
});
我想你還沒有關閉圖片標簽。 可能是這個問題:
var img ='<img src="/assets/Excel_1.png">';
它應該是:
var img ='<img src="/assets/Excel_1.png"></img>';
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.