跨页面刷新

var c;
var timer;
/**
*父页面打开url方法
*/
function parentPageOpen(){
   c = window.open(url);
   timer=window.setInterval("closeWindowCall()", 500);
}

/**
*子页面关闭走if
*/
function closeWindowCall(){
    if(c.closed == true){
		alert("打开的页面关闭啦啦啦啦,刷新吧");
		window.clearInterval(timer);
	}
} 

猜你喜欢

转载自blog.csdn.net/weixin_40845192/article/details/82904544