如何在php中调用具有复杂参数的Soap函数?

时间:2013-05-13 12:53:33

标签: php soap soap-client

我已经搜索了几个小时,为什么我总是在

之后得到一个空对象
<soap:Body>

     <GetFunction xmlns="http://xxx/">

         <thisQuery xsi:type="MyTypeQuery">

               <yourID></yourID>

               <UserType></UserType>

               <Date></Date>

          </thisQuery>
      </GetFunction>
  </soap:Body>

以下是我的称呼方式:

  $client = new SoapClient($URLwithWSDL);
  $GetFunctionResult = $client->GetFunction (array(
           'thisQuery '=>array(

                        'yourID'=>'12345',
                        'UserType'=>'user',
                        'Date'=>'2013-05-13T00:00:00'
                        )
            )
  );
  print_r($GetFunctionResult);

结果是:

  stdClass Object ( [GetFunctionResult] => stdClass Object ( ) ) 

是的,虽然它不应该是空的。

我是所有这些肥皂和新手的新手。 wsdl的事情,所以请善待:)

0 个答案:

没有答案
相关问题