How can I check for an open URL in another window?

前端 未结 6 1783
一个人的身影
一个人的身影 2021-01-01 03:03

This is a follow up to my last question Open a window if the window does not already exist Essentially, I am now keeping a list of all the window references that have been o

6条回答
  •  刺人心
    刺人心 (楼主)
    2021-01-01 03:08

    @annakata (and even if you stored them, you wouldn't have permission to close them any more)

    Not true. If you have the name of the window, you can use window.open to reestablish a link to the window even if the opener was closed and reopened. For example:

    
    Click me first, close and open this window, then
    click me to close the other window
    

提交回复
热议问题