PHP code example of mintellity / laravel-tabbed-session

1. Go to this page and download the library: Download mintellity/laravel-tabbed-session 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/ */

    

mintellity / laravel-tabbed-session example snippets


protected $middleware = [
    // ...
    \Mintellity\LaravelTabbedSession\Http\Middleware\TabbedSessionMiddleware::class,
];

browserTab()->session()->put('foo', 'bar');
browserTab()->session()->get('foo'); // bar

return [
    'exclude' => [
        'admin/*', // Will disable middleware for all paths matching this pattern, e.g. admin/user/create
    ]
]

$this->disableFor(config('tabbed-session.frontend-cookie-name'));

browserTab()->frontendSession()->set('foo', 'bar');
browserTab()->frontendSession()->get('foo'); // bar