1.要求在IE7 和Firefox 下兼容,至少要在IE下可以 而且不需要提示的。(IE version:7.0.5730.13)2.弹出子窗口时,调用js window.open(url), 是一个jsp3.在子窗口有一个 button, 已经试过window.opener.opener = null; window.opener.close();
也试过在父窗口加<OBJECT id=closes type= "application/x-oleobject" classid= "clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11">
<param name= "Command" value= "Close">
</object>
子窗口加 window.parent.document.all.closes.Click();
有这么困难吗,在线等待。。
也试过在父窗口加<OBJECT id=closes type= "application/x-oleobject" classid= "clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11">
<param name= "Command" value= "Close">
</object>
子窗口加 window.parent.document.all.closes.Click();
有这么困难吗,在线等待。。
window.opener.location.href = window.location.href;
window.close();
}
因为父窗口是个list 页面,子窗口是create 页面,当create 结束的时候需要在原来list的页面上显示acknowledge 页面。
var parentWin = window.opener;
if(parentWin != null && !parentWin.closed){
parentWin.document.write(document.body.innerHTML);
window.close();
}
}reDirectToParentWin();
目前的问题是,他还会执行页面上的JavaScript
document.getElementById("myAnchor").href = "www.baidu.com";
}
<A id="myAnchor" href = "http://www.taobao.com">淘宝</A>
<input type="button" value="点击" onLoad="show()">这样不就换地址了吗
但是跨浏览器绝对无解了!
var parentWin = window.opener;
if(parentWin != null && !parentWin.closed){
parentWin.document.open();
parentWin.document.write(document.getElementsByTagName('head')[0].innerHTML);
parentWin.document.write(document.body.innerHTML);
parentWin.document.close();
window.close();
}
}To:xk1126 我要换的是页面的href不是连接的.
现在结贴。