1. Go to this page and download the library: Download invoiceninja/inspector 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/ */
invoiceninja / inspector example snippets
$inspector = new \InvoiceNinja\Inspector\Inspector();
// List all tables in the database
$tables = $inspector->getTableNames();
// Get table columns
$columns = $inspector->getTableColumns('users');
public function index(\InvoiceNinja\Inspector\Inspector $inspector)
{
return view('tables.index', [
'tables' => $inspector->getTableNames(),
]);
}
public function show(string $table, \InvoiceNinja\Inspector\Inspector $inspector)
{
return view('tables.show', [
'columns' => $inspector->getTableColumns($table),
]);
}