borrow parseXML from jquery