unregister_tick_function

De-register a function for execution on each tick

Syntax

unregister_tick_function ( callable $function ) : void

Parameters

function

The function to de-register.

Return

No value is returned.

Examples

1

<?

function myfunction() {
    echo __FUNCTION__ . PHP_EOL;
}

$function = "myfunction";

register_tick_function($function);

declare(ticks = 1);

unregister_tick_function($function);

?>
myfunction

2

<?

function myfunction() {
    echo __FUNCTION__ . PHP_EOL;
}

$function = "myfunction";

register_tick_function($function);
unregister_tick_function($function);

declare(ticks = 1);

?>

			
		

PHP

Home Menu