Set flash message use Session::flash(), after return something from Controller or Model page using Laravel Framework. You need to follow something, that describes in the below of the text:
Use Session:
<?php namespace App/Http/Controllers; use Illuminate/Http/Request; use Session;
Set Flash Message:
if($login==true){ Session::flash('success_message','Log in successfully.'); return redirect('dashboard'); }else{ Session::flash('error_message','Log in Faild!'); return redirect('login_form'); }
Question and answer is powered by AnsPress.io