How to consume WCF WebServices from PHP?
I have to consume a WCF WebServices but the WSDL contains bindings t开发者_C百科hat PHP doesn't support also.
SOAP-ERROR: Parsing WSDL: PHP-SOAP doesn't support transport 'http://schemas.microsoft.com/soap/named-pipe'
How to bypass this problem?
It would seem that you are exposing the service using the net named pipe binding. This more than likely isn't going to work with php because it doesn't know how to speak SOAP/WS over named pipes.
Rather, you will want to use either the basic HTTP binding or the WS HTTP binding to expose your service and then consume it in PHP.
If you have control of the WCF services a solution is to remove manually the unsupported bindings from the WSDL and save the WSDL in another location and point to it using:
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior name="test">
<serviceMetadata
externalMetadataLocation="http://YourServer/Service/MyService.wsdl"/>
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
精彩评论