PHPackages                             neo/hooks - 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. neo/hooks

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

neo/hooks
=========

Implements the wordpress hook functionality for any application.

32862PHP

Since Oct 27Pushed 12y ago1 watchersCompare

[ Source](https://github.com/neoighodaro/hooks)[ Packagist](https://packagist.org/packages/neo/hooks)[ RSS](/packages/neo-hooks/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (2)Used By (0)

PHP-Hooks
=========

[](#php-hooks)

The PHP Hooks Class is a fork of the WordPress filters hook system rolled in to a class to be ported into any php based system

- This class is heavily based on the WordPress plugin API and most (if not all) of the code comes from there.

How to Use?
===========

[](#how-to-use)

Simple, Include the class file in your application bootstrap (setup/load/configuration or whatever you call it) and start hooking your filter and action hooks using the global `$hooks`. Ex:

```
$hooks = new Neo\Hooks\Hook;

$hooks->add_action('header_action','echo_this_in_header');

function echo_this_in_header(){
   echo 'this came from a hooked function';
}
```

Or you can alternatively call the added functions like you would on wordpress

```
add_action('header_action','echo_this_in_header');

function echo_this_in_header(){
   echo 'this came from a hooked function';
}

do_action('action');
```

You can also install it using composer, by adding `"neo/hooks" : "dev-master"` to your composer.json file. You can refer to WordPress API documentation on how to use the hook functionality.

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community5

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/cdfba6ac9dc28ba4134c841782ef374a05e6fb57974b0f106d64cf17e971db39?d=identicon)[neoighodaro](/maintainers/neoighodaro)

### Embed Badge

![Health badge](/badges/neo-hooks/health.svg)

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

###  Alternatives

[markshust/magento2-module-pagebuildersourcecode

The Page Builder Source Code module adds a Source Code button to the toolbar of the Page Builder WYSIWYG editor.

120111.0k](/packages/markshust-magento2-module-pagebuildersourcecode)[igorw/compose

Function composition.

8424.8k](/packages/igorw-compose)

PHPackages © 2026

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