I have the following code that works perfectly. The webservice return is XML
, but the return I'm getting is a string. What should I do to get XML
as a return and not a string?
$client = new SoapClient('http://www.roveri.inf.br/ws/cnpj.php?wsdl');
$function = 'getCNPJ';
$arguments= array(
'token' => $token,
'cnpj' => $cnpj
);
$options = array('location' => 'http://www.roveri.inf.br/ws/cnpj.php');
$result = $client->__soapCall($function, $arguments, $options);
echo 'Response: ';
print_r($result);