WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED INVALID
13347
XMLDom node attributes case is being overridden to lower case???
https://bugs.webkit.org/show_bug.cgi?id=13347
Summary
XMLDom node attributes case is being overridden to lower case???
Sam
Reported
2007-04-13 12:37:04 PDT
I have develloped a JavaScript component that converts XMLDom (AJAX) document into an equivalent JavaScript Object, preserving both node and attribute names. Recently I was trying to fix a site that utilizes this component and is working on every other browser except Safari. What I have discovered shocked me. It turns out that when i'm iterating through XMLNodeAttributes collection all the attribute names are returned in lower case thus overriding what was initialy set in XML. Since I use case sensative way to access attribute values in JavaScript Object, those attributes that had both caps and lower case become inaccessible and logic breaks.
Attachments
Patch
(17.13 KB, patch)
2012-12-05 17:11 PST
,
Jinwoo Song
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
David Kilzer (:ddkilzer)
Comment 1
2007-04-13 18:54:34 PDT
Hi Sam, thanks for the bug report! Have you tried running this on a WebKit nightly build? There have been many improvements since Safari 2.0.x in the WebKit browser engine.
http://nightly.webkit.org/
Alexey Proskuryakov
Comment 2
2007-04-22 02:55:25 PDT
The bug URL is 404 now. Also, there is no such thing as XMLNodeAttributes in WebKit, so it's hard to re-create the problem from description. If I were to guess, this is indeed a bug that has been fixed: the following snippet works in nightly builds, but not in shipping Safari. doc = (new DOMParser).parseFromString("<doc Attr1='1' attr1='11'/>", "application/xml"); for (i = 0; i < doc.documentElement.attributes.length; ++i) document.write("<p>" + doc.documentElement.attributes[i].name + "</p>"); Please reopen this bug if your case is different, and still fails in nightly builds.
Jinwoo Song
Comment 3
2012-12-05 17:11:27 PST
Reopening to attach new patch.
Jinwoo Song
Comment 4
2012-12-05 17:11:31 PST
Created
attachment 177874
[details]
Patch
Jinwoo Song
Comment 5
2012-12-05 17:14:02 PST
Comment on
attachment 177874
[details]
Patch I'm sorry to apply my patch to wrong bug number. It was a patch for
bug 103347
not 13347.
Lucas Forschler
Comment 6
2019-02-06 09:03:04 PST
Mass moving XML DOM bugs to the "DOM" Component.
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