大家快来帮帮我,送上100分 window=>top因为有opener所以他是弹出窗口,可以直接用top.opener=null;top.close(); 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 http://www.csdn.net/expert/Topicview1.asp?id=758864已经说清楚了 iframe 应该用parent而不是opener的看看这个例子:子框架:noname2.html<html><head><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><title></title></head><body><Script Language=JavaScript>function pickup(what){ window.parent.test.value=what; window.parent.testFrame.style.display="none";}</Script><a href="javascript:pickup('微软公司');">微软公司</a><a href="javascript:pickup('英特尔公司');">英特尔公司</a></body></html>父框架:noname3.html (同一个目录下)<html><head><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><title></title></head><body><input id=test onclick="window.testFrame.style.display='' "><BR><div id="testFrame"><iframe src="noname2.html""></iframe></div></body></html> 希望能够帮到你<script>window.open("mainifm.htm","","");</script><form name=calform><input name=Customer></form>mainifm.htm<iframe src=iframe.htm></iframe>iframe.htm<Script Language=JavaScript>function pickup(what){ top.opener.calform.Customer.value=what; top.close();}</Script><a href="javascript:pickup('微软公司');">微软公司</a><a href="javascript:pickup('英特尔公司');">英特尔公司</a>btw,emu(ston):可以用top的 请问这个闭包,造成内存泄漏了吗 jquery 解决ie6.0 position:fixed bug 时间控件问题,哪个大侠帮我下 紧急!!! JS的问题 求JS高手帮忙 谢谢(本人在线等)~~~~~ 关于页面内容的提取 能不能用javascript保存网页中某个部分 如何用正则表达式判断一个字符串是否既含有"convert",又含有"case" ★★★限制弹出窗口个数的问题,比较急★★★ 动态增加控件 获取a标签的innerHTML问题 有两个问题,感觉好象是系统级的,高手来看看吧 请问如何才能关闭整个页面???
看看这个例子:
子框架:noname2.html
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title></title>
</head>
<body><Script Language=JavaScript>
function pickup(what)
{
window.parent.test.value=what;
window.parent.testFrame.style.display="none";
}
</Script>
<a href="javascript:pickup('微软公司');">微软公司</a>
<a href="javascript:pickup('英特尔公司');">英特尔公司</a></body>
</html>父框架:noname3.html (同一个目录下)<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title></title>
</head>
<body>
<input id=test onclick="window.testFrame.style.display='' ">
<BR>
<div id="testFrame">
<iframe src="noname2.html""></iframe>
</div>
</body>
</html>
<script>
window.open("mainifm.htm","","");
</script>
<form name=calform>
<input name=Customer>
</form>mainifm.htm
<iframe src=iframe.htm></iframe>iframe.htm
<Script Language=JavaScript>
function pickup(what)
{
top.opener.calform.Customer.value=what;
top.close();
}
</Script>
<a href="javascript:pickup('微软公司');">微软公司</a>
<a href="javascript:pickup('英特尔公司');">英特尔公司</a>
btw,emu(ston):可以用top的