Issue metadata
Sign in to add a comment
|
Attribute name transformation inconsistency
Reported by
stars...@gmail.com,
Sep 30 2016
|
||||||||||||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.101 Safari/537.36 OPR/40.0.2308.52 (Edition beta) Example URL: https://dl.dropboxusercontent.com/u/10096226/inconsistency.html Steps to reproduce the problem: 1. Have an attribute on an HTML element with uppercase letters 2. Have one of these letters not in the specified range >=0x41 and <=0x5a 3. Try obtaining the attribute with its name What is the expected behavior? The attribute is obtained (and, e.g., can be removed). What went wrong? The attribute cannot be obtained as the transformation that is applied in the tokenizer (following the spec., hence not all upper case letters are changed, only those in range) seems to be different than the one used by the DOM (standard toLower() transformation). Does it occur on multiple sites: Yes Is it a problem with a plugin? No Did this work before? No Does this work in other browsers? Yes Chrome version: 53.0.2785.101 Channel: stable OS Version: 10.0 Flash Version: Shockwave Flash 22.0 r0
,
Oct 3 2016
Please look at the source of the provided URL. From the source it should be clear that "1" and "0" have to be displayed. Other engines, e.g., Gecko or Trident, handle this correctly. The JS in the source reads: ```js var element = document.body.firstElementChild; var name = element.attributes[0].name; alert(name); alert(element.attributes.length); element.removeAttribute(name); alert(element.attributes.length); ```
,
Oct 4 2016
Confirmed that the removeAttribute(..) does actually do something in FireFox.
,
Oct 6 2016
We might be muddling step 1 of "get an attribute by name" [1] which is used by "remove at attribute by name" [2] in case handling. [1] https://dom.spec.whatwg.org/#concept-element-attributes-get-by-name [2] https://dom.spec.whatwg.org/#concept-element-attributes-remove-by-name
,
Apr 14 2017
|
|||||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||||
Comment 1 by rbasuvula@chromium.org
, Oct 3 2016Labels: Needs-Feedback