WC_Queue_Interface::add()publicWC 1.0

Enqueue an action to run one time, as soon as possible

Method of the class: WC_Queue_Interface{}

No Hooks.


String. The action ID


$WC_Queue_Interface = new WC_Queue_Interface();
$WC_Queue_Interface->add( $hook, $args, $group );
$hook(string) (required)
The hook to trigger.
Arguments to pass when the hook triggers.
Default: array()
The group to assign this job to.
Default: ''

WC_Queue_Interface::add() code WC 8.7.0

public function add( $hook, $args = array(), $group = '' );