简体   繁体   中英

Firefox window.opener issue

"window.opener" works fine in both IE and Firefox as long as 'Open in New Tab' is used from the right-click menu; Error console says "window.opener" is null. Is there any other way the opener can be accessed?

Edit: Error console says "window.opener" is null only when "Open in New Tab" is clicked. For all other cases, there is no such error. Hence, what i would like to know is if an alternate other than "window.opener" exists.

window.opener only works if the window (or tab, if it was diverted into a tab) was opened with window.open or via a target attribute or similar. In particular, the UI never sets the opener of a window.

这是window.open() IIRC

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM