working in most browsers, still broken in IE

IE’s DOMParser’s parseFromString method rearranges attribute order
which messes up this whole feature.

They consider this a feature, not a bug, despite every other browser
doing the opposite:
http://stackoverflow.com/questions/4445153/javascript-parsefromstring-ch
anging-order-of-elements-in-xml-doc

Thanks IE.

Possible solutions:
- Parse the document using xmldom client-side?
- Some crazy regex?
- Send angry mob to Microsoft?