0

Rate Quote Rate 报价请求必须发送到以下 URL:SomeIPaddress/cgibin/map/RATEQUOTE 这里是 Rate Quote Request 的示例模式。

<?xml version="1.0" encoding="utf-8" ?>
- <soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchemainstance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
- <soap12:Body>
- <request>
- <Details>
- <DetailItem>
<Weight>decimal</Weight>
<Class>decimal</Class>
</DetailItem>
</Details>
- <Accessorials>
- <AccessorialItem>
<Code>char</Code>
</AccessorialItem>
</Accessorials>
<BillingTerms>Char</BillingTerms>
<OriginCity>Char</OriginCity>
<OriginState>Char</OriginState>
<OriginZipcode>Char</OriginZipcode>
<DestinationCity>Char</DestinationCity>
<DestinationState>Char</DestinationState>
<DestinationZipcode>Char</DestinationZipcode>
<PalletCount>decimal</PalletCount>
<Customer>Char</Customer

我正在为此使用此编码,但它无法显示错误以前我已将这种方法用于许多 API,但我使用 .wsdl 文件:

    <? $client = new SoapClient('http://208.51.75.23:6082/cgi-bin/map/RATEQUOTE',array( 'trace' => 1,'exceptions' => 0 ));

$params = array("Details" => array("DetailItem" =>array("Weight" =>"3","Class" =>"55")),
            "Accessorials" => array("AccessorialItem"=>array("Code" =>"LIFTG")),
            "BillingTerms" => "FEEP", //Billing Terms:Prepaid Collect
            "OriginCity" => "Henrico",
            "OriginState" => "VA",
            "OriginZipcode" => "23229",
            "DestinationCity" => "LOS ANGELES",
            "DestinationState" => "CA",
            "DestinationZipcode" => "90001",
            "PalletCount" => "1",
            "Customer" => "abc",
);
    $return = $client->CreateResult->$params;
    print_r($return);die;



?>
4

1 回答 1

0

您不能,您需要一个 IP 地址或 URL 来连接,或者它需要包含在 WSDL 文件中。否则,你永远不知道在哪里连接......

于 2013-09-11T06:47:44.227 回答