PHP code example of maksmaggot / pricelist-compare

1. Go to this page and download the library: Download maksmaggot/pricelist-compare 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/ */

    

maksmaggot / pricelist-compare example snippets




er = new \Comparator\Reader\CsvPriceListReader();
$firstPriceList = $reader->read(__DIR__ . '/tests/testdata/pricelist.csv');
$secondPriceList = $reader->read(__DIR__ . '/tests/testdata/pricelist2.csv');

$comparator = new \Comparator\PriceListsComparator();
$result = $comparator->compare($firstPriceList, $secondPriceList);