FlashAlert widget

FlashAlert widget collects some flash messages from Yii::$app->session and shows it as alert.

You have an opportunity to set custom flash keys. By default it is error, success, warning and info keys. Also widget has some another settings.

 Success!

Success alert preview. This alert is dismissable.

 Info!

Info alert preview. This alert is dismissable.

 Warning!

Warning alert preview. This alert is dismissable.

 Error!

Danger alert preview. This alert is dismissable. A wonderful serenity has taken possession of my entire soul, like these sweet mornings of spring which I enjoy with my whole heart.

 Code

<?php
Yii::$app->session->setFlash("error", "Danger alert preview. This alert is dismissable. A wonderful serenity has taken possession of my entire soul, like these sweet mornings of spring which I enjoy with my whole heart.");
Yii::$app->session->setFlash("success", "Success alert preview. This alert is dismissable.");
Yii::$app->session->setFlash("warning", "Warning alert preview. This alert is dismissable.");
Yii::$app->session->setFlash("info", "Info alert preview. This alert is dismissable.");
?>
<?= \yiister\adminlte\widgets\FlashAlert::widget(["showHeader" => true]) ?>