PHPackages                             elmyrockers/ezflash - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. elmyrockers/ezflash

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

elmyrockers/ezflash
===================

EzFlash PHP library - Lightweight, simple and easy way to display flash message with Bootstrap 5 (Alert) template

1.0.1(1y ago)1391MITPHPPHP &gt;=7.4

Since Jun 8Pushed 1y ago1 watchersCompare

[ Source](https://github.com/elmyrockers/EzFlash)[ Packagist](https://packagist.org/packages/elmyrockers/ezflash)[ RSS](/packages/elmyrockers-ezflash/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (2)Versions (3)Used By (1)

EzFlash PHP Library
===================

[](#ezflash-php-library)

Lightweight, simple and easy way to display flash message with Bootstrap 5 (Alert) template

Usage/Examples
--------------

[](#usageexamples)

1. First of all, you can install via composer:

    ```
    composer require elmyrockers/ezflash
    ```
2. Add the following line into your PHP code:

    ```
    require_once 'vendor/autoload.php'; //Load Composer's autoloader
    use elmyrockers\EzFlash;
    ```
3. Create new instance of EzFlash class:

    ```
    $message = new EzFlash;
    ```
4. After that, you can set flash message in 4 different ways:

    $message-&gt;{$key} = {$yourmessage};

    ```
    $message->success = 'Message'; //Property
    $message['success'] = 'Message'; //Array key
    $message->success( 'Message' ); //Method call or
    $message( 'success', 'Message' ); //Function call
    ```
5. Then, that flash message can be displayed using echo:

    ```
    echo $message(); //Function call with no parameter
    ```

    Or you can treat this object like a string:

    ```
    echo $message;
    ```

    For instance, if you write code like the following statement:

    ```
    $message( 'success', 'My message' ); //Set flash message through function call
    echo $message; // Echo flash message (one-time display)
    ```

    Then, its output will look like this one:

    ```
    My message
    ```
6. You can set different template for each $key:

    ```
    $message->setTemplate( ['success',
    						'danger',
    						'warning',
    						'info',
    						'primary',
    						'secondary',
    						'light',
    						'dark',
    						'default'], '{$message}' ); //default

    //custom template
    $message->setTemplate( 'errorInfo', '{$message}' );
    ```

    You can override default/existing template too with this.

Reference
---------

[](#reference)

[Simple Tutorial](https://elmyrockers.github.io/EzFlash)

Authors
-------

[](#authors)

[@elmyrockers](https://www.github.com/elmyrockers)

License
-------

[](#license)

[MIT](https://choosealicense.com/licenses/mit/)

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~72 days

Total

2

Last Release

634d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/195bd2a0a6b7ad666b2d7a3790eebbee870c2a3b3adfdef3b3f8982144730abe?d=identicon)[elmyrockers](/maintainers/elmyrockers)

---

Top Contributors

[![elmyrockers](https://avatars.githubusercontent.com/u/6540616?v=4)](https://github.com/elmyrockers "elmyrockers (42 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/elmyrockers-ezflash/health.svg)

```
[![Health](https://phpackages.com/badges/elmyrockers-ezflash/health.svg)](https://phpackages.com/packages/elmyrockers-ezflash)
```

###  Alternatives

[phalcon/zephir

Zephir is a compiled high level language aimed to the creation of C-extensions for PHP

3.4k414.1k18](/packages/phalcon-zephir)[rafaelfragoso/haversini-formula

This PHP class can replace the Google Distance Matrix to calculate the distance between two points using latitude and longitude. It will prevent you to do massive requests to Google servers and enhance your service performance.

45212.0k](/packages/rafaelfragoso-haversini-formula)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
