2017 © Pedro Peláez
 

library flash

Various base classes for flash message management

image

olve/flash

Various base classes for flash message management

  • Thursday, April 28, 2016
  • by Spicachu
  • Repository
  • 1 Watchers
  • 0 Stars
  • 0 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

flash

A flash messagae Anax module, (*1)

A module for Anax

This flash module for your Anax MVC is composed to you by Olivia V. n.a.g.i@live.se., (*2)

How to install

  • Use composer and packagist, (*3)

  • Open the /webroot folder where you will find a demo file and a quick view file, (*4)

  • Copy and paste flash-demo.php to your own /webroot folder for testing, (*5)

  • If the site isn't displayed correctly, move the CFlash.php and CFlashSession to your own /src folder, (*6)

In composer:, (*7)

$ composer require olve/flash, (*8)

Dependencies:, (*9)

"php": ">=5.4", "anax/mvc": "dev-master", (*10)

The module

There are two classes - CFlash.php and CFlashSession. They're both called by the webroot file flash-demo.php., (*11)

The style sheet is called in flash-demo.php as well, "$app->theme->addStylesheet('../vendor/olve/webroot/css/flash.css'", (*12)

Functions

This module will sent success, notice and error messages. It's based off a Phalcon tutorial., (*13)

Sessions

The main code in flash-demo.php will call CFlashSession to ensure that the notice message has survived the redirect., (*14)

Messages

$content .= $app->flash->success('Success message!');
$content .= $app->flash->notice('Notice message.');
$content .= $app->flash->error('Error message');

CSS file

Styles all the messages in a separate letters matter., (*15)

The Versions

28/04 2016

dev-master

9999999-dev http://www.student.bth.se/~olve12/phpmvc/kmom05/webroot/

Various base classes for flash message management

  Sources   Download

MIT

The Requires

 

flash education