Removing dependency on elementtree and just using minidom