该方法在名称中包含一个点并给出错误(DB.GetDocListIden),指定此方法名称的正确方法是什么?
$ result = $ client-> DB.GetDocListIdent($ params);
$wsdl = 'productos.wsdl';
try {
$client = new SoapClient($wsdl);
$params = ['user' => 'user', 'password' => 'pass'];
$result = $client->DB.GetDocListIdent($params);
$productsArray = $result->GetDocListResult->row;
var_dump($productsArray);
foreach($productsArray as $product){
echo '<strong> producto: </strong>' . $product->ItemName;
echo '<br><br>';
}
} catch (SoapFault $fault) {
echo "Fault code: {$fault->faultcode}" . '<br>';
echo "Fault string: {$fault->faultstring}" . '<br>';
if ($client != null) {
$client = null;
}
exit();
}
catch(Exception $ex){
echo $ex->getMessage();
}
$client = null;
&#13;
答案 0 :(得分:0)
您可以使用__soapCall
,例如:
$client = new SoapClient('');
$client->__soapCall("DB.function", [args]);