Web servis + çağrısı isteği form verilerini gönderme

0 Cevap php

Ben bir web hizmeti için belirli bir kullanıcı veri gönderen bir sistem oluşturma sürecinde yaşıyorum. Temelde, kullanıcı adını, telefon numarasını ve referans numarasını girer. Daha sonra o hemen veya belirli bir zamanında denir olmadığını seçer. Gönderilen Bu bilgiler daha sonra bir çevirici sisteme eklenir ve aramaları geri oluşturulur.

Ben web sitesi hizmeti biraz belgeleri ile sağlanmıştır. Ne yazık ki, onunla nasıl çalışmaya hala beni kaçar. Ben formu tasarlanmış ve gerekli doğrulama ekledik. Belgelere bu ekler:

Saklı yordam alan adları ve değerleri kabul edecek

  • a) işlem talep üzerine yürütülecek.
  • b) Bayrak (İletişim Numaraları OR İletişim Numarası) NOT 10 ile 15 arasında bir geçersiz uzunluğa sahip için belirtilen telefon numarasını kayıt reddetti.
  • c) parametre koleksiyonunda geçerli telefon numaralarını yerleştirin. Biri var olmamalıdır Amcat telefon numarasına bir lider 0 (sıfır) katacak
  • d) ContactPhoneNumbers tabloya telefon numaralarını yerleştirin.
  • e) ContactInfo ve içine veri ekleme Verilen parametreler ile tabloları ContactDetails. Hiçbir parametre değeri belirtilmemişse varsayılan değer eklenecektir.
  • XML tarafından belirlenen bir alan adı daha sonra yoksa f) bir uyarı, bir dize olarak web servisi tarafından iade edilecektir, ancak irtibat numarası hala girilebilir ve arama gönderilecektir.
  • g) bir anlık kadranı yürütmek için gerekli detayları dön.

Ve bu beklenen XML formatında türüdür ... Özür dilerim bu oldukça uzun ise:

<?xml version="1.0" encoding="utf-8" ?>
<wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
  xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:s="http://www.w3.org/2001/XMLSchema"
  xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://tempuri.org/"
  xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
  xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" targetNamespace="http://tempuri.org/"
  xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
  <wsdl:types>
    <s:schema elementFormDefault="qualified" targetNamespace="http://tempuri.org/">
      <s:element name="Call">
        <s:element name="CallResponse">
          <s:complexType>
            <s:sequence>
              <s:element minOccurs="0" maxOccurs="1" name="CallResult"
                type="s:string" />
            </s:sequence>
          </s:complexType>
        </s:element>
        <s:element name="string" nillable="true" type="s:string" />
    </s:schema>
  </wsdl:types>
  <wsdl:message name="CallSoapIn">
    <wsdl:message name="CallSoapOut">
      <wsdl:part name="parameters" element="tns:CallResponse" />
    </wsdl:message>
    <wsdl:message name="CallHttpGetIn">
      <wsdl:part name="xmlString" type="s:string" />
    </wsdl:message>
    <wsdl:message name="CallHttpGetOut">
      <wsdl:part name="Body" element="tns:string" />
    </wsdl:message>
    <wsdl:message name="CallHttpPostIn">
      <wsdl:part name="xmlString" type="s:string" />
    </wsdl:message>
    <wsdl:message name="CallHttpPostOut">
      <wsdl:part name="Body" element="tns:string" />
    </wsdl:message>
    <wsdl:portType name="CallRequestSoap">
      <wsdl:operation name="Call">
        <wsdl:input message="tns:CallSoapIn" />
        <wsdl:output message="tns:CallSoapOut" />
      </wsdl:operation>
    </wsdl:portType>
    <wsdl:portType name="CallRequestHttpGet">
      <wsdl:operation name="Call">
    </wsdl:portType>
    <wsdl:portType name="CallRequestHttpPost">
      <wsdl:operation name="Call">
        <wsdl:input message="tns:CallHttpPostIn" />
        <wsdl:output message="tns:CallHttpPostOut" />
      </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name="CallRequestSoap" type="tns:CallRequestSoap">
      <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
      <wsdl:operation name="Call">
        <soap:operation soapAction="http://tempuri.org/Call" style="document" />
        <wsdl:input>
          <soap:body use="literal" />
        </wsdl:input>
        <wsdl:output>
          <soap:body use="literal" />
        </wsdl:output>
      </wsdl:operation>
    </wsdl:binding>
    <wsdl:binding name="CallRequestHttpGet" type="tns:CallRequestHttpGet">
      <http:binding verb="GET" />
      <wsdl:operation name="Call">
        <http:operation location="/Call" />
        <wsdl:input>
          <http:urlEncoded />
        </wsdl:input>
        <wsdl:output>
          <mime:mimeXml part="Body" />
        </wsdl:output>
      </wsdl:operation>
    </wsdl:binding>
    <wsdl:binding name="CallRequestHttpPost" type="tns:CallRequestHttpPost">
      <http:binding verb="POST" />
      <wsdl:operation name="Call">
        <http:operation location="/Call" />
        <wsdl:input>
          <mime:content type="application/x-www-form-urlencoded" />
        </wsdl:input>
        <wsdl:output>
          <mime:mimeXml part="Body" />
        </wsdl:output>
      </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="CallRequest">
      <documentation xmlns="http://schemas.xmlsoap.org/wsdl/" />
      <wsdl:port name="CallRequestSoap" binding="tns:CallRequestSoap">
        <soap:address location="http://localhost/ClickToCall/CallRequest.asmx" />
      </wsdl:port>
      <wsdl:port name="CallRequestHttpGet" binding="tns:CallRequestHttpGet">
        <http:address location="http://localhost/ClickToCall/CallRequest.asmx" />
      </wsdl:port>
      <wsdl:port name="CallRequestHttpPost" binding="tns:CallRequestHttpPost">
        <http:address location="http://localhost/ClickToCall/CallRequest.asmx" />
      </wsdl:port>
    </wsdl:service>
</wsdl:definitions>

Ben bu yüzden burada tamamen kaybettim, nasıl böyle bir şey yapılabilir alabilirim? Ben SOAP böyle bir şey yer olduğunu biliyorum ... ama ne yapmak ... Yani herhangi bir yardım takdir olurdu hiç bir fikrim yok.

Teşekkürler

Sam

0 Cevap