2017 © Pedro Peláez
 

library hooks

A simple php framework for adding runtime hooks to a system.

image

kel/hooks

A simple php framework for adding runtime hooks to a system.

  • Friday, February 2, 2018
  • by KEL
  • Repository
  • 0 Watchers
  • 0 Stars
  • 3 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Hooks

A simple php framework for adding runtime hooks to a system., (*1)

installation, (*2)

$ composer require kel/hooks
````

**example**

```php
use Kel\Load;
use Kel\Hooks;

//create a new Hooks instance 
//passing an array of config options is optional
//__NB: Multiple hooks can be added to the same hook point__
$hook = new  Hooks(Load::config(__DIR__.'/config.php'));

//add a hook init.php to the hook point init
//the hook point is created if it does not exist 
$hook->add_hook('init', "init.php"); 

//add a hook init.php to the hook point final
$hook->add_hook('final', "init.php");

//run the hook init
$hook->run_hook('init');

//run the hook final
$hook->run_hook('final');

The Versions

02/02 2018

dev-master

9999999-dev

A simple php framework for adding runtime hooks to a system.

  Sources   Download

MIT

The Requires

  • php 5.6|^7.0

 

02/02 2018

v1.0.1

1.0.1.0

A simple php framework for adding runtime hooks to a system.

  Sources   Download

MIT

The Requires

  • php 5.6|^7.0