function xmlconvert($source) { $xml = new Xml2Array(); $xml->setXml($source); $array = $xml->get_array(); return $array; }