PHP Класс dmstr\widgets\Alert

php \Yii::$app->getSession()->setFlash('error', 'Alert! Danger alert preview. This alert is dismissable.'); Multiple messages could be set as follows: php \Yii::$app->getSession()->setFlash('error', ['Error 1', 'Error 2']);
Автор: Evgeniy Tkachenko ([email protected])
Наследование: extends yii\bootstrap\Widget
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$alertTypes the alert types configuration for the flash messages. This array is setup as $key => $value, where: - $key is the name of the session flash variable - $value is the array: - class of alert type (i.e. danger, success, info, warning) - icon for alert AdminLTE
$closeButton the options for rendering the close button tag.
$isAjaxRemoveFlash whether to removed flash messages during AJAX requests

Открытые методы

Метод Описание
init ( ) Initializes the widget.

Описание методов

init() публичный Метод

This method will register the bootstrap asset bundle. If you override this method, make sure you call the parent implementation first.
public init ( )

Описание свойств

$alertTypes публичное свойство

the alert types configuration for the flash messages. This array is setup as $key => $value, where: - $key is the name of the session flash variable - $value is the array: - class of alert type (i.e. danger, success, info, warning) - icon for alert AdminLTE
public $alertTypes

$closeButton публичное свойство

the options for rendering the close button tag.
public $closeButton

$isAjaxRemoveFlash публичное свойство

whether to removed flash messages during AJAX requests
public $isAjaxRemoveFlash