laravel flash message

Flash Messages in Laravel 5

Second Step: Calling the flash in the View

Adding flash message is simple, all you have to do is to call session(‘name_of_your_flash‘) in the view. 

If want to have great display of flash, you have to know about using Bootstrap Alert Class. Basically there are four types of alerts in twitter bootstrap:

  • success
  • information
  • warning
  • danger

Each one of these CSS classes should match the type of message you want to display. For example, if you successfully added a record in your model, it should be the success flash that will display, or if there are some errors in your app, you can use the danger flash.

Sharing is caring!