PHP code example of smallruraldog / admin

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

    

smallruraldog / admin example snippets


return [
    'default' => 'mysql',
    'connections' => [
        'mysql' => [
            'driver' => 'mysql',
            'host' => getenv('DB_HOST'),
            'port' => getenv('DB_PORT'),
            'database' => getenv('DB_DATABASE'),
            'username' => getenv('DB_USERNAME'),
            'password' => getenv('DB_PASSWORD'),
            'unix_socket' => getenv('DB_SOCKET'),
            'charset' => 'utf8mb4',
            'collation' => 'utf8mb4_unicode_ci',
            'prefix' => '',
            'strict'      => true,
            'engine'      => null,
        ],
    ],
];

base_path() . '/admin',

if (DIRECTORY_SEPARATOR === '/' && isset($this->loadedFiles[$file->getRealPath()])) {
    //echo "$file updated but cannot be reloaded because only auto-loaded files support reload.\n";
    //continue;
}
shell
php webman smallruraldog-admin:install
shell
php webman smallruraldog-admin:assets
shell
php start.php start