- From: Peter Kelly <pmk@kde.org>
- Date: Sat, 8 Feb 2003 17:36:39 +1030 (CST)
- To: <www-dom-ts@w3.org>
Hi, Section 1.3 of the DOM Level 2 HTML spec states: "element and attribute names are exposed as all uppercase (for consistency) when used on an HTML document, regardless of the character case used in the markup" However, some of the test cases rely on the attribute name being returned as lowercase, even though the document is html. For example, in hc_attrname.html in the jsunit tests: streetAttr = attributes.getNamedItem("class"); strong = streetAttr.nodeName; assertEquals("nodeName","class",strong); Other tests, such as hc_nodecloneattributescopied.html expect uppercase: for(var _index = 0; _index < attributes.length; _index++) { attributeNode = attributes.item(_index); attributeName = attributeNode.nodeName; result[result.length] = attributeName; } assertEqualsCollection("nodeNames",this.builder.toAutoCaseArray(expectedResult),result); Mozilla & IE both return the nodeName as lowercase, but KHTML returns it as uppercase. Am I correct in assuming this is the correct behaviour? -- Peter Kelly pmk@kde.org
Received on Saturday, 8 February 2003 02:06:33 UTC