您的位置:首页 > 其它

如何点击按钮弹出新窗口,输入数据后返回并刷新页面[转载]

2008-04-29 20:57 836 查看
第一种方法:

父窗口代码

<a href="#" onclick="window.open('child.html','child','width=400,height=300,left=200,top=200');">打开子窗口</a>

子窗口代码

<script language="JavaScript" type="text/javascript">

function refreshParent()

{ window.opener.location.href = window.opener.location.href;

if (window.opener.progressWindow)

{

window.opener.progressWindow.close();

}

window.close();

}

</script>

防止弹出的子窗口,再弹出窗口可在:

<head>

<base target= "_self " />

</head>

第二种方法:

如何点击按钮弹出新窗口,输入数据后返回并刷新页面?


作者:孟宪会 出自:【孟宪会之精彩世界】
http://dotnet.aspx.cc/ShowDetail.aspx?id=49ML4AO8-5PB3-4KNY-NJZD-LJOIOXV4M1X4
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐