子窗體刷新父窗體

parent.htm頁面
 1 < script language = " JavaScript " >
 2 <!--
 3 function  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 <!--
 4 function  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(); " >
相關文章
相關標籤/搜索