PHP code example of usmonaliyev / env-auth
1. Go to this page and download the library: Download usmonaliyev/env-auth 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/ */
usmonaliyev / env-auth example snippets
protected $routeMiddleware = [
// Other middleware
'basic.env' => \Usmonaliyev\EnvAuth\Middleware\BasicEnv::class,
'secret.env' => \Usmonaliyev\EnvAuth\Middleware\SecretEnv::class,
];
Route::middleware('basic.env')->group(function () {
...
});
bash
php artisan vendor:publish --provider="Usmonaliyev\EnvAuth\EnvAuthServiceProvider"