Download the PHP package devsrv/laravel-session-out without Composer

On this page you can find all versions of the php package devsrv/laravel-session-out. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-session-out

Session expired message for your Laravel application

Latest Version on Packagist GitHub license Total Downloads GitHub issues

If for any reason ( user logged out intentionally / session lifetime expired / session flushed for all logged in devices of the user ) the authentication session doesn't exist & still the user is on a page or multiple pages which require the user to be logged in, then showing a message that

authentication session no longer available & to continue your current activity ( may be in the middle of posting an unsaved post etc. ), you are advised to login again

and right after user logged in then hiding the message is all about this package.

📥 Installation

You can install the package via composer:

Laravel 5.5+ users: this step may be skipped, as we can auto-register the package with the framework.

You need to publish the blade, js, css and config files included in the package using the following artisan command:

⚗️ Usage

just include the blade file to all the blade views which are only available to authenticated users.

rather copying this line over & over to the views, extend your base blade view and include it there in the bottom

🛠 Configuration

✔ The Config File

publishing the vendor will create config/expiredsession.php file

✔ If you want to take advantage of broadcasting

** if you are using avail_broadcasting = true i.e. want to use the Laravel Echo for faster output please follow the below steps

  1. setup broadcasting for your app and start usersession queue worker

  2. make sure to put the broadcasting client config js file above the @include line not below it, in your blade view.

  3. in App\Providers\BroadcastServiceProvider file in the boot method require the package's channel file, it contains private channel authentication

  4. in all the places from where users are authenticated call devsrv\sessionout\classes\AuthState::sessionAvailable() . if you are using custom logic to login users then put the line inside your authentication method when login is successful.

    if you are using laravel's default authentication system then better choice will be to create a listener of the login event, Example :-

✔ Update the modal design & contents

The modal is created with pure js and css no framework has been used, so you can easily customize the modal contents by editing the views/vendor/sessionout/modal.blade.php & the design by editing public/vendor/sessionout/css/session-modal.css

✔ Advanced

🧐📑 Note

♻ When updating the package

Remember to publish the assets, views and config after each update

use --force tag after updating the package to publish the updated latest package assets, views and config

but remember using --force tag will replace all the publishable files

when updating the package take backup of the config/expiredsession.php file & public/vendor/sessionout, views/vendor/sessionout directories as the files inside these dir. are configurable so if you modify the files then the updated published files will not contain the changes, though after publishing the assets, views and config you may again modify the files

🔧 After you tweak things

Run this artisan command after changing the config file.

👋🏼 Say Hi!

Let me know in Twitter | Facebook if you find this package useful 👍🏼

🎀 License

The MIT License (MIT). Please see License File for more information.


All versions of laravel-session-out with dependencies

PHP Build Version
Package Version
Requires php Version ^7.1.3
illuminate/support Version ^5.7
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package devsrv/laravel-session-out contains the following files

Loading the files please wait ....