finished off downloadXMLasJSON