【发布时间】:2013-02-20 04:45:10
【问题描述】:
在 twitter 引导程序中是否有带有 ajax 微调器的标准弹出窗口?虽然应该是,但我没有找到任何关于它的信息。
【问题讨论】:
在 twitter 引导程序中是否有带有 ajax 微调器的标准弹出窗口?虽然应该是,但我没有找到任何关于它的信息。
【问题讨论】:
这就是我在使用 Font Awesome 的 Ajax 调用(如已接受的答案中所建议的那样)并稍微调整模态样式的方法:
<!-- CSS -->
<style>
#spinner-modal .modal-dialog,
#spinner-modal .modal-content,
#spinner-modal .modal-body {
background: transparent;
color: rgba(255,255,255,1);
box-shadow: none;
border: none;
}
</style>
<!--[ SPINNER MODAL ]-->
<div class="modal fade" id="spinner-modal">
<div class="modal-dialog modal-sm">
<div class="modal-content">
<div class="modal-body text-center">
<h3><i class="fa fa-cog fa-spin"></i> Working...</h3>
</div>
</div>
</div>
</div>
<!--[ JS ]-->
<script>
$('#search-form-input').autocomplete({
source: '/search.php',
minLength: 2,
select: function(event, ui) {
$('#spinner-modal').modal('show');
var url = '/a/results/index.php?i=' + ui.item.item_id;
window.location.href = url;
}
});
</script>
【讨论】:
您可以使用引导模式插件http://twitter.github.com/bootstrap/javascript.html#modals 在弹出窗口中加载 ajax 内容。
没有一种引导方式来拥有微调器,但您可以在显示模式弹出窗口之前自行完成。
【讨论】: