PHP code example of hfoletto / edi-proceda

1. Go to this page and download the library: Download hfoletto/edi-proceda 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/ */

    

hfoletto / edi-proceda example snippets

 
$file_contents = file_get_contents('OCO10032021_160647.txt');
$ocoren = new \EdiProceda\Ocoren($file_contents);
print_r($ocoren);

echo $ocoren->ocorrencias[0]->getDescricao(); // Retornará "Entrega realizada normalmente"
echo $ocoren->ocorrencias[0]->getObservacao(); // Retornará "Aceite/entrega de acordo"
 
$file_contents = file_get_contents('CONEMB10032021_160647.txt');
$conemb = new \EdiProceda\Conemb($file_contents);
print_r($conemb);