WordPress at Your Fingertips
function is not described

Requests_Hooks::dispatch() public WP 1.0

Dispatch a message

{} It's a method of the class: Requests_Hooks{}

No Hooks.


true|false. Successfulness


$Requests_Hooks = new Requests_Hooks();
$Requests_Hooks->dispatch( $hook, $parameters );
$hook(string) (required)
Hook name
Parameters to pass to callbacks

Code of Requests_Hooks::dispatch() WP 5.8

public function dispatch($hook, $parameters = array()) {
	if (empty($this->hooks[$hook])) {
		return false;

	foreach ($this->hooks[$hook] as $priority => $hooked) {
		foreach ($hooked as $callback) {
			call_user_func_array($callback, $parameters);

	return true;