October 19, 2015

Saving User cookie on Login Laravel 5.x

Updated 03/02/2016

You’ll also need to make sure you tell your Events listeners to listen appropriately:

If you need to store the user_id (or any value for that matter) as a cookie when a User logs in, simply add (or edit) the app/Listeners/AuthLoginListener.php to include the following:

written by Jake Litwicki - Posted in Random


2 thoughts on “Saving User cookie on Login Laravel 5.x

Leave a Reply

Your email address will not be published. Required fields are marked *