PHP code example of samad / array-conversion

1. Go to this page and download the library: Download samad/array-conversion 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/ */

    

samad / array-conversion example snippets

bash
composer install samad/array-conversion
bash
$toTableInitiate = new ArrayConversion($data);
$toTableInitiate->toTable()
bash
$addColumnToTable = new ArrayConversion($data);

$addColumnToTable->addColumn('Action', function ($data) {
    return '<button class="btn btn-success btn-xs">Action</button>';
})->toTable();
bash
$editColumn = new ArrayConversion($data);
$editColumn->editColumn('email', function ($data) {
    return 'Email: ' . $data['email'];
})->toTable();