Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

use middleware in controller to have access session

$this->middleware(function($request,$next){
  if (session('success')) {
  	Alert::success(session('success'));
  }

  if (session('error')) {
  	Alert::success(session('error'));
  }

  return $next($request);
});
 
PREVIOUS NEXT
Tagged: #middleware #controller #access #session
ADD COMMENT
Topic
Name
6+3 =