uopz_undefine
PHP function
Edit on GitHub ✎
(PECL uopz 1, PECL uopz 2, PECL uopz 5, PECL uopz 6, PECL uopz 7)
Undefine a constant
Description
uopz_undefine(string $constant): bool
uopz_undefine(string $class, string $constant): bool
Removes the constant at runtime
Parameters
classThe name of the class containing
constantconstantThe name of an existing constant
Return Values
Success
Examples
uopz_undefine() example
php
<?php
define("MY", true);
uopz_undefine("MY");
var_dump(defined("MY"));
?>The above example will output:
output
bool(false)