DEV Community

Discussion on: Different Ways to Redirect User

Collapse
 
bdelespierre profile image
Benjamin Delespierre • Edited

You can also flash session data using with like this:

return redirect('dashboard')->with('status', 'Profile updated!');

Meanwhile, in the view:

@if (session('status'))
    <div class="alert alert-success">
        {{ session('status') }}
    </div>
@endif

Read more here: laravel.com/docs/7.x/responses#red...