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

前端 未结 6 1744
一个人的身影
一个人的身影 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:03

    In JavaScript, you can only gain references to the current window and any windows that you open with window.open.

    You could check for winRef.closed to see if the user closed the window, though. I'm not sure if this works well on all browsers or not, though.

提交回复
热议问题