Ich schrieb einen SoapServer in PHP-Projekt.Wenn ich soapCall mit PHP bin alles ok.Ab wenn eine andere Person in .net meine WSDL verwendet, hat einen Fehler.Was ist die Lösung? Ich habe angebracht Fehler, WSDL, SoupUi Ergebnis und functions.Thankful.enter Bildbeschreibung hier.net kann nicht meine soapServer verwenden
dies panel.wsdl
<?xml version="1.0" encoding="ISO-8859-1"?>
<definitions
targetNamespace='urn:server'
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:tns='urn:server'
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<types>
<xsd:schema targetNamespace='urn:server' xmlns="urn:server">
<xsd:import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
<xsd:import namespace="http://schemas.xmlsoap.org/wsdl/" />
<xsd:complexType name="getActiveServicesResponse">
<xsd:complexContent>
<xsd:restriction base="SOAP-ENC:Array">
<xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="xsd:string[]" minOccurs="1" maxOccurs="unbounded"/>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="getHistoryServicesResponse">
<xsd:complexContent>
<xsd:restriction base="SOAP-ENC:Array">
<xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="xsd:string[]" minOccurs="1" maxOccurs="unbounded"/>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="getHistoryServicesAllResponse">
<xsd:complexContent>
<xsd:restriction base="SOAP-ENC:Array">
<xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="xsd:string[]" minOccurs="1" maxOccurs="unbounded"/>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
</xsd:schema>
</types>
<message name="getActiveServicesRequest">
<part name="username" type="xsd:string" />
<part name="password" type="xsd:string" />
<part name="mobileNum" type="xsd:string" /></message>
<message name="getActiveServicesResponse">
<part name="services" type="tns:getActiveServicesResponse" /></message>
<message name="unsubscribeRequest">
<part name="username" type="xsd:string" />
<part name="password" type="xsd:string" />
<part name="mobileNum" type="xsd:string" />
<part name="serviceID" type="xsd:string" /></message>
<message name="unsubscribeResponse">
<part name="result" /></message>
<message name="getHistoryServicesAllRequest">
<part name="username" type="xsd:string" />
<part name="password" type="xsd:string" />
<part name="mobileNum" type="xsd:string" />
<part name="FromDate" type="xsd:string" />
<part name="ToDate" type="xsd:string" /></message>
<message name="getHistoryServicesAllResponse">
<part name="history" type="tns:getHistoryServicesAllResponse" /></message>
<message name="getHistoryServicesRequest">
<part name="username" type="xsd:string" />
<part name="password" type="xsd:string" />
<part name="mobileNum" type="xsd:string" />
<part name="serviceID" type="xsd:string" />
<part name="FromDate" type="xsd:string" />
<part name="ToDate" type="xsd:string" /></message>
<message name="getHistoryServicesResponse">
<part name="history" type="tns:getHistoryServicesResponse" /></message>
<portType name="iPanelPortType">
<operation name="getActiveServices">
<input message="tns:getActiveServicesRequest"/>
<output message="tns:getActiveServicesResponse"/>
</operation>
<operation name="unsubscribe">
<input message="tns:unsubscribeRequest"/>
<output message="tns:unsubscribeResponse"/>
</operation>
<operation name="getHistoryServicesAll">
<input message="tns:getHistoryServicesAllRequest"/>
<output message="tns:getHistoryServicesAllResponse"/>
</operation>
<operation name="getHistoryServices">
<input message="tns:getHistoryServicesRequest"/>
<output message="tns:getHistoryServicesResponse"/>
</operation>
</portType>
<binding name="iPanelBinding" type="tns:iPanelPortType">
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="getActiveServices">
<soap:operation soapAction="urn:server#getActiveServices" style="rpc"/>
<input><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
<output><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
</operation>
<operation name="unsubscribe">
<soap:operation soapAction="urn:server#unsubscribe" style="rpc"/>
<input><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
<output><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
</operation>
<operation name="getHistoryServicesAll">
<soap:operation soapAction="urn:server#getHistoryServicesAll" style="rpc"/>
<input><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
<output><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
</operation>
<operation name="getHistoryServices">
<soap:operation soapAction="urn:server#getActiveServices" style="rpc"/>
<input><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
<output><soap:body use="encoded" namespace="urn:server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
</operation>
</binding>
<service name="iPanel">
<port name="iPanelPort" binding="tns:iPanelBinding">
<soap:address location="http://37.130.202.161/integratedPanel?wsdl"/>
</port>
</service>
</definitions>
Funktionen
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Exception;
use App\Notification;
use App\LogNotification;
use Log;
class ServiceBinding extends Controller
{
public function getActiveServices($username,$password,$mobilNum)
{
return "hello";
}
public function unsubscribe($username,$password,$mobilNum,$serviceID)
{
return "hello";
}
public function getHistoryServicesAll($username,$password,$mobilNum,$toDate,$fromDate)
{
return "hello";
}
public function getHistoryServices($username,$password,$mobilNum,$serviceID,$toDate,$fromDate)
{
return "hello";
}
}
?>
aktionseife
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Exception;
use Log;
class IntegratedPanelController extends Controller
{
public function soap() {
try{
ini_set('soap.wsdl_cache_enabled', 0);
ini_set('soap.wsdl_cache_ttl', '0');
$server = new \SoapServer('/home/sysadmin/VAS_mci/public/wsdl/panel.wsdl', array('cache_wsdl' => WSDL_CACHE_NONE));
$server->setClass("App\Http\Controllers\ServiceBinding");
try {
$server->handle();
}
catch (Exception $e) {
echo 'IntegratedPanelController.........'. $e->getMessage();
log::info($e->getMessage());
$server->fault('Sender', $e->getMessage());
}
// echo "SOAP Server started";
}
catch (Exception $exception){
echo 'IntegratedPanelController.........'.$exception->getMessage();
log::info($exception->getMessage());
return $exception->getMessage();
}
}
}