javascript - 在iframe子页面 通过window.parent.document打开父页面的modal层不能正常关闭
阿神
阿神 2017-07-05 11:06:17
0
3
1084

大家好 我想问一下 在iframe子页面 通过window.parent.document打开父页面的modal层,这样父页面的modal关闭方法$("#modal").modal("hide")不能正常关闭,有没有大神知道这是什么原因

阿神
阿神

闭关修行中......

全部回复(3)
学霸

雷雷

漂亮男人

$('#id', window.parent.document).modal('隐藏');

phpcn_u1582

最后采取了一种不太好的方法暂时解决,先show再hide,$("#modal").modal("show").modal("hide"),这样可以解决,只是弹出层关闭的时候会因为show闪一下,还没有找到好的解决办法

热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责声明 Sitemap
PHP中文网:公益在线PHP培训,帮助PHP学习者快速成长!