Skip to content

Kirby 4.5.0

$kirby->trigger()

Trigger a hook by name

$kirby->trigger(string $name, array $args = [ ], ?Kirby\Cms\Event $originalEvent = null): void

Parameters

Name Type Default Description
$name * string Full event name
$args array [ ] Associative array of named event arguments
$originalEvent Kirby\Cms\Event|null null Event object (internal use)

Parent class

Kirby\Cms\App