getAttribute does not behave correctly for mixed-case attributes on HTML elements