WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
17977
REGRESSION(3.0-3.1): Safari/WebKit initializes variables to dom elements
https://bugs.webkit.org/show_bug.cgi?id=17977
Summary
REGRESSION(3.0-3.1): Safari/WebKit initializes variables to dom elements
David den Boer
Reported
2008-03-20 19:22:37 PDT
I have in my html a variable named foo. In my html, I have a div element named foo. In javascript, I check to see if variable foo is undefined, and if so, I take action. Expected result : action in javascript executes for foo. Actual result : foo gets defined to the div element foo automatically.
Attachments
Reduction for ticket
(833 bytes, text/html)
2008-03-20 19:26 PDT
,
David den Boer
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
David den Boer
Comment 1
2008-03-20 19:26:34 PDT
Created
attachment 19918
[details]
Reduction for ticket simple test case. If the bug is present, the alert displays the dom node, otherwise it displays a message.
Mark Rowe (bdash)
Comment 2
2008-03-20 20:00:50 PDT
You've marked this as a regression: what is it a regression from?
David den Boer
Comment 3
2008-03-20 20:05:15 PDT
Behaves correctly in Safari 3.0.4
Mark Rowe (bdash)
Comment 4
2008-03-20 20:12:28 PDT
This may have been an intentional change in behaviour.
Mark Rowe (bdash)
Comment 5
2008-03-20 20:12:56 PDT
<
rdar://problem/5811736
>
Geoffrey Garen
Comment 6
2008-04-29 11:17:53 PDT
IE7, Firefox2, and Opera 9 all disagree with Safari's behavior.
Ahmad Saleem
Comment 7
2022-07-21 12:53:10 PDT
I am unable to reproduce this bug in Safari 15.6 on macOS 12.5 based on attached test case (assuming it is correct - it does not have any errors in Console) and the browser shows dialog box saying 'This is correct behaviour'. It matches with all other browsers (Chrome Canary 105 and Firefox Nightly 104). I think it was fixed along the way and this can be marked as "RESOLVED CONFIGURATION CHANGED". If I am testing incorrectly, please test accordingly. Thanks!
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