Check if window is already open window.open

前端 未结 5 2032
我寻月下人不归
我寻月下人不归 2020-12-01 16:15

I have a html page. In the body of the page I am calling onload event which calls javascript function to open a pop up window. here is the code:



        
5条回答
  •  醉酒成梦
    2020-12-01 16:41

    Use the "closed" property: if a window has been closed its closed property will be true. https://developer.mozilla.org/en-US/docs/Web/API/Window/closed

提交回复
热议问题