a.html--------------------------
<html>
<body>
<a οnclick="javascript:window.open('b.html');">OpenNewWindow</a>
</body>
<html>
b.html--------------------------
<html>
<body onUnload="javascript:opener.location.href='a.html';">
<a οnclick="javascript:window.close(this)">[CloseWindow]</a>
</body>
</html>
父页是显示标题,弹出页修改标题提交后,父页更新:
<script language=javascript>
function winclose() {
window.opener.location.reload();
window.close();
}
</script>
<input type=button name=close value="关闭" οnclick=winclose()>
父页面:
<script>
function aaa()
{
alert("parent window function");
}
</script>
<a href="" οnclick="window.open('csdn_onunload.htm')" target="_blank">aaaaa</a>
子叶面,也就是 'csdn_onunload.htm'
<body Onunload="opener.aaa();">
hello
</body>