Download the PHP package elmyrockers/ezflash without Composer
On this page you can find all versions of the php package elmyrockers/ezflash. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download elmyrockers/ezflash
More information about elmyrockers/ezflash
Files in elmyrockers/ezflash
Package ezflash
Short Description EzFlash PHP library - Lightweight, simple and easy way to display flash message with Bootstrap 5 (Alert) template
License MIT
Informations about the package ezflash
EzFlash PHP Library
Lightweight, simple and easy way to display flash message with Bootstrap 5 (Alert) template
Usage/Examples
-
First of all, you can install via composer:
-
Add the following line into your PHP code:
-
Create new instance of EzFlash class:
-
After that, you can set flash message in 4 different ways:
$message->{$key} = {$yourmessage};
-
Then, that flash message can be displayed using echo:
Or you can treat this object like a string:
For instance, if you write code like the following statement:
Then, its output will look like this one:
-
You can set different template for each $key:
You can override default/existing template too with this.