C
C
chelkaz2016-03-13 01:55:35
Laravel
chelkaz, 2016-03-13 01:55:35

Where is the session going?

If I catch right after installation, then it is of course
public function destroy($id)
{
Session::flash('message', 'ok');
dd(Session::get('message'));
return Redirect::to('/admin/service/adboard/');
}
And if in the view,
QuestionsController.php
Then NULL ... Why is it lost? There is only one redirect, a one-time session.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
Eugene, 2016-03-13
@Eugene_H

Do the routes have web middleware?

V
Vyacheslav Plisko, 2016-03-13
@AmdY

That's right, flash data is available only on the next request, this is described in the documentation

Flash Data
Sometimes you may wish to store items in the session only for the next request.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question