Pau*_*iel 2 javascript fancybox
我正在尝试重定向到.fancybox的"onclose"属性上的URL ...它只是起作用.有任何想法吗?代码如下.注意:模态看起来很好,但是当用户按下顶部的"x"时......屏幕只是空白.
<script type="text/javascript">
showModal();
function showModal() {
var url = document.URL;
var popUp = '//local.meau.com/Support-Center/Service-Notifications/Search-Tips.aspx';
var site = popUp;
$(document).ready(function () {
$.fancybox({
'width': 500,
'height': '55%',
'autoScale': false,
'transitionIn': 'none',
'transitionOut': 'none',
'type': 'iframe',
'href': site,
'showCloseButton': true,
'onClose' : function(){location.href = "http://local.meau.com/Support-Center.aspx";}
});
});
}
</script>
Run Code Online (Sandbox Code Playgroud)
更新了您的代码以便阅读
window.location = "http://local.meau.com/Support-Center.aspx"
Run Code Online (Sandbox Code Playgroud)
仔细检查你的onClose回调
callbackOnCloseonClosedbeforeClose或
afterClose| 归档时间: |
|
| 查看次数: |
7342 次 |
| 最近记录: |