$hooksremoveHook()

Given a Hook ID provided by addHook() this removes the hook

To have a hook function remove itself within the hook function, say this is your hook function: function(HookEvent $event) { $event->removeHook(null); // remove self }

Usage

$wire = $hooks->removeHook(Wire $object, $hookID);

Arguments

NameType(s)Description
$objectWire
$hookIDstring array null

Can be single hook ID, array of hook IDs, or CSV string of hook IDs

Return value


$hooks methods and properties

API reference based on ProcessWire core version 3.0.251