关闭子页面刷新父页面 在网上看到很多解决关闭子页面刷新父页面的方法,但是还是没有我想要的,基本上都是在子页面上加个按钮然后实现关闭子页面刷新父页面,那么这样就不能达到点击子页面右上方的叉关闭子页面刷新父页面的效果,不知道怎么能实现点击子页面右上方的叉关闭子页面来达到刷新父页面的效果。求教求教 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <script language=javascript>window.top.location.href='父页面‘;window.opener=null;window.close();</script>先刷新父页面,在关闭子页面如果一开始进到父页面时子页面还没打开,那直接刷新父页面就行了试试吧 子页面中写Response.Write("<script>window.opener.location.href = window.opener.location.href;if(window.opener.progressWindow) window.opener.progressWindow.close();window.close();</script>"); var returnValue = window.showModalDialog(url,window,"dialogHeight=350px;dialogWidth=400px;center=yes;status=no;scroll=no;resizable=yes");window.unLoad = function(){window.dialogArgument.location.reload();}; http://hi.baidu.com/netspirit/blog/item/0b3be0fd2952331a08244d45.html <script language="javascript">function Method(){ window.opener.location=window.opener.location;}</script> <body onbeforeunload="Method();"> 子function window.onbeforeunload(){ window.opener.refreshPage(); } 父function refreshPage(){ window.location.reload(); } textbox只能输入数字 我要实现窗体最大化,最小化,拖动,拉伸的特效谁有代码给我啊? asp.net 静态化和伪静态哪个好 加密代码的疑问 二问 为什么把网页的内容保存了 using System.Security.Cryptography;加解密问题,高手进,在线等,谢谢 请问如何对集合排序 请问asp.net配置方面的问题--首页和数据库连接超时的配置问题 为什么有两个名字呢? 初学者问题之八? 为什么 onunload="window.open('新窗口的文件名.htm');"在火狐中不起作用呢 网页处理问题
window.top.location.href='父页面‘;window.opener=null;window.close();
</script>
先刷新父页面,在关闭子页面
如果一开始进到父页面时子页面还没打开,那直接刷新父页面就行了
试试吧
window.unLoad = function(){window.dialogArgument.location.reload();};
function Method(){
window.opener.location=window.opener.location;
}
</script>
<body onbeforeunload="Method();">
function window.onbeforeunload(){
window.opener.refreshPage();
} 父
function refreshPage(){
window.location.reload();
}