当模态窗口关闭但它不起作用时,我试图调用一个函数。
我的代码是:
<script type="text/javascript">
$('#myModal').bind('hidden', function () {
alert("blah");
});
</script>
<div id="myModal" class="modal hide fade">
<div class="modal-header">
<a class="close" data-dismiss="modal">×</a>
<br />
Test
</div>
<div class="modal-body">
<p>Modal body</p>
</div>
<div class="modal-footer">
<a href="#" class="btn primary">Primary</a>
<a href="#" class="btn secondary">Secondary</a>
</div>
</div>
<button type="button" data-toggle="modal" data-target="#myModal">Launch modalbggg</button>
有任何想法吗?