Answer the question
In order to leave comments, you need to log in
Using Soap for Parsing
I came across this code:
$client = new SoapClient("http://www.cbr.ru/DailyInfoWebServ/DailyInfo.asmx?WSDL");
print "<pre>";
print_r($client->EnumValutes(false));
Answer the question
In order to leave comments, you need to log in
Maybe he gets the full answer, you just don’t see the whole picture in print_r, it goes a lot to the left, and plus the tags are hidden. You'd better use var_dump() to output the answer.
$oRet = $client->EnumValutes();
$oXml = simplexml_load_string($oRet->EnumValutesResult->any);
foreach ($oXml->ValuteData->EnumValutes as $oCurr) {
echo $oCurr->VcharCode . '|' . $oCurr->VnumCode . '|' . $oCurr->Vname . '<br/>';
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question