2017 © Pedro Peláez
 

yii2-extension yii2-alert-session

alert extension for Yii2

image

maximkozhin/yii2-alert-session

alert extension for Yii2

  • Tuesday, August 8, 2017
  • by maximkozhin
  • Repository
  • 1 Watchers
  • 0 Stars
  • 9 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

Alert Extension for Yii2

Via composer

add to your 'require' section in file 'composer.json', (*1)

 "require": {
       ...
        "maximkozhin/yii2-alert-session": "*"
    },

or run command, (*2)

$ composer require maximkozhin/yii2-alert-session

1. Configuration | Конфигурация

insert into you config file, (*3)

'components' => [
    ...
   'session' => [
       'class' => 'maximkozhin\alert\components\session',
       'flashIndex' => 'flash'
   ],
   ...

2. Usage | Использование

To create a Flash Message, (*4)

Yii::$app->session->addFlash($type, $message);
or
Yii::$app->session->setFlash($type, $message);

Your flash messages don't group by type, outputing by the FIFO principe, (*5)

2. Layout | Вывод

add to your layout file, (*6)

...
<!-- CSS styles in css-file /your/vendor/path/maximkozhin/alert/dist/css/alert.css -->
<div class="flash-messages">
    <?=\maximkozhin\alert\widgets\Alert::widget()?>
</div>
...

The Versions

08/08 2017

dev-master

9999999-dev

alert extension for Yii2

  Sources   Download

MIT

The Requires

 

by Maxim Kozhin

extension yii2 widget session alert

03/08 2017

1.0.1

1.0.1.0

alert extension for Yii2

  Sources   Download

MIT

The Requires

 

by Maxim Kozhin

extension yii2 widget session alert

18/05 2017

1.0.0

1.0.0.0

alert extension for Yii2

  Sources   Download

MIT

The Requires

 

by Maxim Kozhin

extension yii2 widget session alert