Closed Bug 1169645 Opened 6 years ago Closed 6 years ago
Attribute() returns null for attributes containing upper case characters in attribute name
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Firefox/38.0 20150513174244 Works for me. Have you actually tested just the code you posted, without anything else on the page? If yes, please test in a brand new profile. https://support.mozilla.org/kb/profile-manager-create-and-remove-firefox-profiles
I did not, in fact, test the exact code I posted when I created the issue report. That was code simplified from the actual code I had a problem with. I just created a simple test that should have failed and did not. It definitely happens in my "real" code that would not be at all convenient to share since it depends on a lot of other moving parts. Others have reported the same symptoms however, so I ask you not to close this issue just yet. I will look through my production code and try to find out what else happens to trigger the behavior I have reported and try to create a test case that fails so you can find this. Give me a couple of hours.
Ok, I see what happened in the real code. I used createAttribute() and setNamedAttribute() (code was written 8 years ago). That function has been deprecated, but should still function properly and still needs fixing. I will attach a test case to show you what is actually occurring.
John, thanks for hunting that down. This is the same as bug 1165851, then. Per the spec for createAttribute what you're doing should in fact not work (because createAttribute creates the attribute with that case, but getAttribute lower-cases its argument before doing case-sensitive compares), but it sounds like the spec needs changing...
Status: UNCONFIRMED → RESOLVED
Closed: 6 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1165851
You need to log in before you can comment on or make changes to this bug.