[SOLVED]Re: WCF & PHP SOAP
| From: | Kris | Date: | Wed, 27 Feb 2008 22:33:28 +0000 |
| Subject: | [SOLVED]Re: WCF & PHP SOAP | ||
| References: | 1 | Groups: | php.soap |
| Request: | Send a blank email to php-soap+get-2772@lists.php.net to get a copy of this message | ||
In my WCF I was using wsHttpBinding instead of basicHttpBinding.
I don't think PHP yet supports the later although it has more features.
""Kris"" <klh@iti-global.com> wrote in message
news:73.21.14752.005B5C74@pb1.pair.com...
>I have a .NET WCF hosted by a windows service which my PHP app needs to
>communcate with.
>
> I am trying a very simple example and cannot get them linked:
>
> PHP CODE
> --------------------
> $wsdl_url =
> "http://localhost:8000/LimmWatcherController/service?wsdl";
> $client = new SoapClient($wsdl_url);
>
> $params->nodeId = 7455;
>
> var_dump($client->__getFunctions());
>
> $result = $client->__soapCall('GetModelFile',array('parameters' =>
> $params));
>
> RESULT
> --------------------
> array(1) { [0]=> string(59) "GetModelFileResponse
> GetModelFile(GetModelFile $parameters)" }
> Fatal error: Uncaught SoapFault exception: [HTTP] Unsupported Media Type
> in c:\Inetpub\wwwroot\mastermodel\testService.php:9 Stack trace: #0
> [internal function]: SoapClient->__doRequest('<?xml version="...',
> 'http://localhos...',
> 'http://tempuri....', 1, 0) #1
> c:\Inetpub\wwwroot\mastermodel\testService.php(9):
> SoapClient->__soapCall('GetModelFile', Array) #2 {main} thrown in
> c:\Inetpub\wwwroot\mastermodel\testService.php on line 9
>
> Notice that the first line here accurately shows my method so I'm assuming
> I'm incorrectly identifying my parameters.?.
>
> I can access this through any .NET client and the function just returns a
> Hello World string (no processing to rule out issues with the method).
>
> Any ideas?
>
> Thank you,
>
> Kris