I keep loosing session data on redirect for users with Internet Explorer on my L5 website.
Session data lost on normal redirect. I don't seem to be alone (10,000 views ie9 loses cookies after redirect
). But even explicitly flashed data is lost on redirect, see second redirect version of code ->with()
.
I have done the basic homework and added P3P as part of header based on Stackoverflow suggestions.
First Controller
public function getVerifyClient(){
// If user is an existing client
if(\Auth::check()){
if (\Auth::user()->role == 'Client'){
// dd(Session::get('service')); <-- Selected service part of session
return redirect('order'); <-- Session data lost
return redirect('order')->with('service', Session::get('service'); <-- Session data lost even with explicitly flashed data
}
\Auth::logout(); // Logout employees etc so they do not book in their account
}
...
}
Second controller
public function getOrder(){
dd(Session::get('service'));
}
Session.php
My session.php is set to normal standards ('domain' => null, 'path' => '/'
etc), only exception is 'encrypt'
which is set to true
rather than false
.