gpt4 book ai didi

javascript - bPopup jQuery 模态主体不显示

转载 作者:行者123 更新时间:2023-12-02 16:01:41 24 4
gpt4 key购买 nike

所以我尝试使用 bPopup 作为模态窗口,但我看不到弹出实际的模态窗口。我按照文档上的说明进行操作(请参阅 http://dinbror.dk/bpopup/ ),但我似乎无法让它出现。我错过了什么吗?

    <html>
<script type = "text/javascript" src = "jquery-1.11.3.min.js"></script>
<script type = "text/javascript" src = "jquery.bpopup.min.js"></script>
<p> Some text </p>
<div style="display:none" id='popup'>
Why is there no modal body???
</div>
<script type = "text/javascript">
$(document).ready(
function(){
$('p').click(function(){
$('#popup').bPopup();
})
})
</script>
</html>

生成的脚本如下所示: Before Click点击后,结果是这样的: After Click

但是,在文档上,模式如下: enter image description here

我真的不确定我错过了什么。我可能只是对一些非常明显的事情视而不见,有什么想法吗?

最佳答案

你读过这篇文章吗?

What is bPopup? bPopup is a lightweight jQuery modal popup plugin (only 1.49KB gzipped). It doesn't create or style your popup but provides you with all the logic like centering, modal overlay, events and more. It gives you a lot of opportunities to customize so it will fit your needs.


所以你需要为模态窗口编写自己的样式。

关于javascript - bPopup jQuery 模态主体不显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31149952/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com