Brimbox Logo Brimbox Version 2.3.4 Released

add_action>>

Method to add an action to the global array ($array_global). Although typically used for hooks and action links, any global array with an associative key, a priority and a callable function can manipulated with this method.

Class: bb_build, called as $main

File: bb_build.php (php)

Declaration:

function add_action($name, $action, $value, $priority = 0)

Usage:

$main->add_action($name, $action, $value, $priority)

global $array_global

Parameter: $name (name)
Will add $value to the global array $array_global using parameters $name, $action and $priority. Actions do not have a definite key, generally the $action, a callable function in $value and $priority form a key.

Parameter: $action (string)
The associative key for the array.

Parameter: $value (string)
The value associated with the array. Should contain a callable function.

Parameter: $priority (mixed)
An integer added to $value using associative key ‘priority’, which is sorted when executing hooks for execution order.

Updated: 2017-08-27