our company has a .net base website
a few days ago we request a webservice from our website programmer and yesterday he sent me a URL
when i open the URL from localhost its shown a page that i can choose one of my four method (function) that we request to programming.
by choosing one of them a new page has boon shown as follow:
SOAP 1.1
The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.
POST /webservices/findstatus.asmx HTTP/1.1 Host: localhost
Content-Type: text/xml; charset=utf-8 Content-Length: length
SOAPAction: "http://tempuri.org/FindWith_CodeR_Serail"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<FindWith_CodeR_Serail xmlns="http://tempuri.org/">
<CodeReception>int</CodeReception>
<Serial>string</Serial>
</FindWith_CodeR_Serail>
</soap:Body>
</soap:Envelope>
HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<FindWith_CodeR_SerailResponse xmlns="http://tempuri.org/">
<FindWith_CodeR_SerailResult>string</FindWith_CodeR_SerailResult>
</FindWith_CodeR_SerailResponse>
</soap:Body>
</soap:Envelope>
SOAP 1.2
The following is a sample SOAP 1.2 request and response. The placeholders shown need to be replaced with actual values.
POST /webservices/findstatus.asmx HTTP/1.1 Host: localhost
Content-Type: application/soap+xml; charset=utf-8 Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
<soap12:Body>
<FindWith_CodeR_Serail xmlns="http://tempuri.org/">
<CodeReception>int</CodeReception>
<Serial>string</Serial>
</FindWith_CodeR_Serail>
</soap12:Body>
</soap12:Envelope>
HTTP/1.1 200 OK Content-Type: application/soap+xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
<soap12:Body>
<FindWith_CodeR_SerailResponse xmlns="http://tempuri.org/">
<FindWith_CodeR_SerailResult>string</FindWith_CodeR_SerailResult>
</FindWith_CodeR_SerailResponse>
</soap12:Body>
</soap12:Envelope>
HTTP POST
The following is a sample HTTP POST request and response. The placeholders shown need to be replaced with actual values.
POST /webservices/findstatus.asmx/FindWith_CodeR_Serail HTTP/1.1
Host: localhost Content-Type: application/x-www-form-urlencoded
Content-Length: length CodeReception=string&Serial=string
HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8
Content-Length: length
<?xml version="1.0" encoding="utf-8"?>
<string xmlns="http://tempuri.org/">string</string>
Now i'm stock on php codes that call this web service with 2 parameter
please send me full code that i can paste it in a php file for test.
no matter what kind of method is used : SOAP or HTTP POST
please help me.
i used this php code and every thing is OK:
<?php
$client = new SoapClient("http://www.MyWebSite.com/webservices/findstatus.asmx?WSDL");
$params=new stdClass();
$params->CodeReception = '11111';
$params->Serial = '22222222';
$result = $client->FindWith_CodeR_Serail($params)->FindWith_CodeR_SerailResult;
echo $result;
?>