PHP code example of misterbrownrsa / laravel-dhl-api

1. Go to this page and download the library: Download misterbrownrsa/laravel-dhl-api library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

misterbrownrsa / laravel-dhl-api example snippets


dump($GetCapability->toXML());

dump($GetCapability->doCurlPost());
dump($GetCapability->requestRAW());

$product = [];
foreach ($cart->items as $key => $cartItem) {
    for ($i = 1; $i <= $cartItem->quantity; $i++) {
        $product[ $key ]['height'] = $box['height'];
        $product[ $key ]['depth'] = $box['length'];
        $product[ $key ]['width'] = $box['width'];
        $product[ $key ]['weight'] = $cartItem->warehouse->product->weight + $box1['weight'];
    }
}

dump($GetQuote->results());
dump($GetQuote->resultsRAW());