Constant Expression¶
A constant expression is an expression built with others constants and a limited subset of PHP operators. They can be used as a value for constants of default values.
<?php
const A = 1;
const B = A + 1;
?>
A constant expression is an expression built with others constants and a limited subset of PHP operators. They can be used as a value for constants of default values.
<?php
const A = 1;
const B = A + 1;
?>
The definitive reference with all things PHP, and their definitions.
Contents: