dev-master
9999999-devPHP class for create and display flashmessages
MIT
The Requires
- php >=5.4
- anax/mvc dev-master
message flash flasmessages
Wallogit.com
2017 © Pedro Peláez
PHP class for create and display flashmessages
PHP class for create and display flashmessages. It is created as a module for Anax-MVC, see https://github.com/mosbth/Anax-MVC. https://travis-ci.org/yvonnej/flashmessages.svg?branch=master, (*2)
By Yvonne I Johansson, (*3)
This software is free software and carries a MIT license., (*4)
2015-01-21 - 1.0, (*5)
First you need to add the flashmessages module to your pagecontroller (or your CDIFactoryDefault):, (*6)
$di->set('flash', function() use ($di){
$flash = new \Yvos\FlashMessages\CFlashMessage();
$flash->setDI($di);
return $flash;
});
Then you can use it to set message:, (*7)
$this->flash->error("This is an error message");
To retrieve messages:, (*8)
$this->flash->getMessage();
If you want to use my styling, copy flash.css from weboot to your css foleder and add this to your router:, (*9)
$app->theme->addStyleSheet('css/flash.css');, (*10)
Add yvonnej/flashmessages to your composer.json like this:, (*11)
{ "require": { "yvonnj/flashmessages": "dev-master" } }, (*12)
PHP class for create and display flashmessages
MIT
message flash flasmessages