WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 174891
Bug 178145
Anchor targeting does not work right with javascript: URLs
https://bugs.webkit.org/show_bug.cgi?id=178145
Summary
Anchor targeting does not work right with javascript: URLs
Boris Zbarsky
Reported
2017-10-10 14:32:10 PDT
STEPS TO REPRODUCE: 1. Load the testcase. 2. Click the link. EXPECTED RESULTS: The alert should say "Should be about:blank: about:blank" ACTUAL RESULTS: The alert says: "Should be about:blank: XXXX" where XXXX is the actual url of the testcase page. ADDITIONAL INFORMATION: The HTML spec is pretty clear on this: the target is used to find the right browsing context before any script gets run, and then it runs in the current window in the target browsing context. Safari is running it in the wrong window. Note, in particular, that this: <a href="javascript:alert(location.href)" target="_blank">Click me</a> should open a new window and then run the JS in there, which Safari also doesn't do.
Attachments
Testcase
(147 bytes, text/html)
2017-10-10 14:32 PDT
,
Boris Zbarsky
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Boris Zbarsky
Comment 1
2017-10-10 14:32:38 PDT
Created
attachment 323352
[details]
Testcase
Anne van Kesteren
Comment 2
2017-10-10 22:49:33 PDT
*** This bug has been marked as a duplicate of
bug 174891
***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug