子窗体刷新父窗体
Submitted by 浪淘沙 on 2007, June 21, 1:51 PM. ajax.net
 parent.htm页面
 1<script language="JavaScript">
 2<!--
 3function cd()
 4{
 5    win=window.open("son.htm","win","width=200,height=200");
 6}
 7//-->
 8</script>
 9<input type="button" value="子页面" onclick="cd();">
10<p>
11<input type="text" name="">    son.htm页面
 1<title>子页面</title>
 2<script language="JavaScript">
 3<!--
 4function reflesh()
 5{
 6
 7
 8    window.opener.opener=null;window.opener.location.reload();  //实现父窗体刷新
 9//    window.opener.opener=null;window.opener.navigate('parent.htm'); //实现父窗体重新加载
10}
11//-->
12</script>
13<input type="button" value="刷新" onclick="reflesh();">
我用网上的代码测试 也是提示 无效的过程调用或参数操作系统win2003+iis6
是否系统有关?

解决方案 »

  1.   

    window.opener.parent.frames["Under"].document.location.reload(); 
      

  2.   

    在操作系统winxp+iis6中运行 没出现错误
    这是怎么回事 
      

  3.   

    你的代码ie6测试没有问题window.opener.location.reload();  
      

  4.   

    window.opener.location.reload();
    win2003为啥不能reload呢
      

  5.   

    window.open一个网页window.opener.location.reload();  windows2003系统下不行 是不是有限制?window.location.reload(); 刷新当前页面可以
      

  6.   

    1.htm:
    <script language="JavaScript">
    <!--
    function cd()
    {
       win=window.open("2.htm","win","width=200,height=200");
    }
    //-->
    </script>
    <input type="button" value="子页面" onclick="cd();">
    <p>
    <input type="text" name="">2.htm<title>子页面</title>
    <script language="JavaScript">
    <!--
    function reflesh()
    {
       opener.window.location=' http://www.baidu.com';}
    //-->
    </script>
    <input type="button" value="刷新" onclick="reflesh();">
    我要在2.htm多点击 刷新 按钮 1.htm才刷新
    这是为啥是不是ie有问题或window2003限制
    window.opener.location.reload();  不行  window.location.reload(); 刷新当前页面可以
      

  7.   

    可能ie问题
    今天就没以上问题了另增问题
    模式方式打开子窗体刷新父窗体框架中的子框架问题 
    http://topic.csdn.net/u/20080508/10/81c55c8d-427e-4ace-9bf3-b7fbfaa47ed1.html