PHP code example of neronplex / cake-orm-enabler

1. Go to this page and download the library: Download neronplex/cake-orm-enabler 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/ */

    

neronplex / cake-orm-enabler example snippets


// providers array in config/app.php
Neronplex\CakeORMEnabler\ServiceProvider::class,

// add line in bootstrap/app.php
$app->register(Neronplex\CakeORMEnabler\ServiceProvider::class);

// aliases array in config/app.php
'aliases' => [
    // other facades...
    'TableRegistry' => Neronplex\CakeORMEnabler\Facades\TableRegistry::class,
],

// add line in bootstrap/app.php (5.2 or earlier)
if (!class_exists('TableRegistry'))
{
    class_alias('Neronplex\CakeORMEnabler\Facades\TableRegistry', 'TableRegistry');
}
  
// add line in bootstrap/app.php (5.3 or later)
$app->withFacades(TRUE, [
    // other facades...
    'Neronplex\CakeORMEnabler\Facades\TableRegistry' => 'TableRegistry',
]);