jeudi 25 avril 2019

Laravel Request cookie doesn't show JS created Cookies

I'm using JS-Cookie for setting a Cookie via the front-end. Why can't I access it in my Laravel 5.8 application with: dd(request()->cookies)? The Cookie is visible with the name, but the value is null. But when I do try to get the Value of the Cookie via the "normal" way, I do get the value: dd($_COOKIE['the-cookie-value-i-want']);.

How can I access the value of the Cookie via the "Laravel-way"? Which is more secure.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire