PHP code example of komicho / laravel-user-online
1. Go to this page and download the library: Download komicho/laravel-user-online 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/ */
komicho / laravel-user-online example snippets
\LaravelEG\Laravel\Middleware\UserOnlineMiddleware::class
use LaravelEG\Laravel\Traits\UserOnline;
class User extends Authenticatable
{
use UserOnline;
...
Auth::user()->isOnline();