bootstrap调用iframe

var frameSrc = "http://www.devtoutiao.com/";

$('#openBtn').click(function(){     
	$('#myModal').on('show', function () {
		$('iframe').attr("src",frameSrc);        
	});
	$('#myModal').modal({show:true}) 
});
<a id="openBtn" href="#">Open modal</a>

<div id="myModal" role="dialog" tabIndex="-1">  
	<div>   
		<button class="close" type="button" data-dismiss="modal">×</button>    
		<h3>Dialog</h3>  
	</div>  
	<div class="modal-body">       
		<iframe style="zoom: 0.6;" height="250" src="" frameBorder="0" width="99.6%"></iframe>  
	</div>  
	<div>   
		<button data-dismiss="modal">OK</button>  
	</div> 
</div>

演示

演示

原创文章:bootstrap调用iframe ,未经许可,禁止转载,©版权所有
原文出处:前端开发博客 (http://caibaojian.com/bootstrap-iframe.html)