http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-July/297135.html starting from http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-March/253865.html When a window is opened by a frame A and then it's navigated to another page by frame B, then the new window's opener should still point to A per the specification.
I think this might just be a matter of adding an |if (created) { }| around https://trac.webkit.org/browser/trunk/Source/WebCore/page/DOMWindow.cpp?rev=142755&order=name#L1887 Although, it could well be more complicated and involve more places in the code.
(In reply to comment #0) > http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-July/297135.html > starting from http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-March/253865.html > > When a window is opened by a frame A and then it's navigated to another page by frame B, > then the new window's opener should still point to A per the specification. I'm having a bit of rough time figuring out who is navigating who in this. Can someone attach a test case?
(In reply to comment #2) > (In reply to comment #0) > > http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-July/297135.html > > starting from http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-March/253865.html > > > > When a window is opened by a frame A and then it's navigated to another page by frame B, > > then the new window's opener should still point to A per the specification. > > I'm having a bit of rough time figuring out who is navigating who in this. Can someone attach a test case? The test case is in http://lists.whatwg.org/pipermail/whatwg-whatwg.org/2014-July/297135.html: http://fiddle.jshell.net/t4sgd/show/ Chrome and Firefox alert "true"; IE alerts "false". The spec says "false" should be alerted. -Boris
Chris, did we fix this issue?
(In reply to comment #4) > Chris, did we fix this issue? No we did not. The behavior is still the same in Safari Technology Preview. That said, no other browser (besides Edge) seems to have implemented this either.
Here's the test case: https://lists.w3.org/Archives/Public/public-whatwg-archive/2014Jul/0005.html
Here are updated test results: Test Case Link (Updated) - https://jsfiddle.net/t4sgd/show/ ** Safari 15.6 on macOS 12.5 ** Clicking on "Click me first" leads to opening in about:blank in background and then clicking on "Click me second" leads to opening another about:blank in background but show "true" dialog ** Chrome Canary 106 ** Clicking on "Click me first" leads to opening in about:blank in foreground (have to focus back to test case) and then clicking on "Click me second" leads to opening another about:blank in foreground but show "true" dialog upon checking back on test case similar to Safari ** Firefox Nightly 105 ** Clicking on "Click me first" leads to opening in about:blank in foreground (have to focus back to test case) and then clicking on "Click me second" leads to opening another about:blank in foreground but show "true" dialog upon checking back on test case similar to Safari ___________ NOTE - All browsers show "true" for the test case but Safari open the iframe or tabs in background while other in foreground. It might be browser preference or settings but just wanted to share updated results. Thanks!
The spec has since changed to match Gecko / WebKit at this point.