Reputation: 33
I am new in working with Laravel, currently I am working with sessions. I got a bit confused with the syntax on how to save session variables. ¿Could you help me?
Thank you for your help.
Upvotes: 3
Views: 64
Reputation: 56
To add global variables all you have to do is
session()->regenerate();
session()->put('name', $value);
and that should add it to your session variables
Upvotes: 1