PHP code example of ebrahemalwish / laravel-multi-guard

1. Go to this page and download the library: Download ebrahemalwish/laravel-multi-guard 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/ */

    

ebrahemalwish / laravel-multi-guard example snippets


Route::group(['middleware' => ['admin.auth']], function () {
    // protected routes
});
bash
php artisan multi-guard:build
bash
php artisan multi-guard:remove

GET  /{guard}/login           → login page
POST /{guard}/login/check     → authenticate
POST /{guard}/logout          → logout        [protected]
GET  /{guard}/dashboard       → dashboard     [protected]
bash
php artisan migrate
php artisan db:seed