4 * Interface to flash add method
7 * @param string $name Variable name
8 * @param mixed $value Value that need to be set
11 function flash_add($name, $value) {
12 Flash
::instance()->addVariable($name, $value);
16 * Shortcut method for adding success var to flash
19 * @param string $message Success message
22 function flash_success($message) {
23 flash_add('success', $message);
27 * Shortcut method for adding error var to flash
30 * @param string $message Error message
33 function flash_error($message) {
34 flash_add('error', $message);
38 * Return variable from flash. If variable DNX NULL is returned
41 * @param string $name Variable name
44 function flash_get($name) {
45 return Flash
::instance()->getVariable($name);