Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Below is DHL rate calculator code: You need to change siteid and password with your DHL siteid and password. </p> <pre><code>&lt;?php $data = '&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;p:DCTRequest xmlns:p="http://www.dhl.com" xmlns:p1="http://www.dhl.com/datatypes" xmlns:p2="http://www.dhl.com/DCTRequestdatatypes" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.dhl.com DCT-req.xsd "&gt; &lt;GetQuote&gt; &lt;Request&gt; &lt;ServiceHeader&gt; &lt;MessageTime&gt;'.date('c').'&lt;/MessageTime&gt; &lt;MessageReference&gt;1234567890123456789012345678901&lt;/MessageReference&gt; &lt;SiteID&gt;YOUR_DHL_SITE_ID&lt;/SiteID&gt; &lt;Password&gt;YOUR_DHL_PASSWORD&lt;/Password&gt; &lt;/ServiceHeader&gt; &lt;/Request&gt; &lt;From&gt; &lt;CountryCode&gt;GB&lt;/CountryCode&gt; &lt;Postalcode&gt;WC1A&lt;/Postalcode&gt; &lt;/From&gt; &lt;BkgDetails&gt; &lt;PaymentCountryCode&gt;US&lt;/PaymentCountryCode&gt; &lt;Date&gt;2011-06-06&lt;/Date&gt; &lt;ReadyTime&gt;PT10H21M&lt;/ReadyTime&gt; &lt;ReadyTimeGMTOffset&gt;+01:00&lt;/ReadyTimeGMTOffset&gt; &lt;DimensionUnit&gt;CM&lt;/DimensionUnit&gt; &lt;WeightUnit&gt;KG&lt;/WeightUnit&gt; &lt;Pieces&gt;&lt;Piece&gt; &lt;PieceID&gt;1&lt;/PieceID&gt; &lt;Height&gt;20&lt;/Height&gt; &lt;Depth&gt;20&lt;/Depth&gt; &lt;Width&gt;20&lt;/Width&gt; &lt;Weight&gt;19&lt;/Weight&gt; &lt;/Piece&gt;&lt;/Pieces&gt; &lt;IsDutiable&gt;N&lt;/IsDutiable&gt; &lt;NetworkTypeCode&gt;AL&lt;/NetworkTypeCode&gt; &lt;/BkgDetails&gt; &lt;To&gt; &lt;CountryCode&gt;US&lt;/CountryCode&gt; &lt;Postalcode&gt;10101&lt;/Postalcode&gt; &lt;/To&gt; &lt;/GetQuote&gt; &lt;/p:DCTRequest&gt;'; $tuCurl = curl_init(); curl_setopt($tuCurl, CURLOPT_URL, "https://xmlpitest-ea.dhl.com/XMLShippingServlet"); curl_setopt($tuCurl, CURLOPT_PORT , 443); curl_setopt($tuCurl, CURLOPT_VERBOSE, 0); curl_setopt($tuCurl, CURLOPT_HEADER, 0); curl_setopt($tuCurl, CURLOPT_POST, 1); curl_setopt($tuCurl, CURLOPT_RETURNTRANSFER, 1); curl_setopt($tuCurl, CURLOPT_POSTFIELDS, $data); curl_setopt($tuCurl, CURLOPT_HTTPHEADER, array("Content-Type: text/xml","SOAPAction: \"/soap/action/query\"", "Content-length: ".strlen($data))); $tuData = curl_exec($tuCurl); curl_close($tuCurl); $xml = simplexml_load_string($tuData); print "&lt;pre&gt;"; print_r($xml); ?&gt; </code></pre> <p>For more reference click on below link:</p> <p><a href="http://xmlpitest-ea.dhl.com/serviceval/jsps/main/Main_menu.jsp">http://xmlpitest-ea.dhl.com/serviceval/jsps/main/Main_menu.jsp</a></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload