. Net provides the wcf interface, which can be accessed by deploying IIS! Response) I use phpsoap to call and test whether it can be used. it is also possible: __getfunctions (); echo & quot; related data structure n & quot ;; print_r ($ c interface php parameter
The. net-based wcf interface can be accessed by deploying IIS.
I use php soap to call and test whether it can be passed. it is also possible:
Header ('content-Type: text/plain ');
$ Client = new SoapClient ('http: // testu.sh.jinri.com/Flight.User.SOA/SuggestService.svc? Wsdl ');
Echo'
';
Echo "provided Method \ n ";
Print_r ($ client->
GetFunctions ());
Echo "related data structure \ n ";
Print_r ($ client->GetTypes ());
Echo '';
?>
Result displayed on the browser
Call this method in wcf: GetSuggestList
This method is like this in the interface:
Public GetSuggestListResponse GetSuggestList (GetSuggestListRequest request)
So the parameter is an object.
My PHP call is as follows:
$ Client = new SoapClient ('http: // testu.sh.jinri.com/Flight.User.SOA/SuggestService.svc? Wsdl ');
$ Param = array ('userid' => '2013', 'pageindex' => '1', 'pagesize' => '5 ');
Print_r ($ client-> GetSuggestList ($ param ));
However, this error is thrown:
Fatal error: Uncaught SoapFault exception: [a: InternalServiceFault] The object reference is not set to the instance of the object. In D: \ APMServ5.2.6 \ www \ htdocs \ wsdltest \ index. php: 22 Stack trace: #0 [internal function]: SoapClient->__ call ('getsuggestlist', Array) #1 D: \ APMServ5.2.6 \ www \ htdocs \ wsdltest \ index. php (22): SoapClient-> GetSuggestList (Array) #2 {main} thrown inD: \ APMServ5.2.6 \ www \ htdocs \ wsdltest \ index. php on line 22
Please help me. it's been a whole day and I don't know why.