Undefined Constants¶
Undefined global constants used to fallback to their equivalent string. It would keep the execution going, too. In PHP 8.0, such mistake is a Fatal Error
PHP code¶
<?php
echo D;
?>
Before¶
D
After¶
Uncaught Error: Undefined constant "D"
PHP version change¶
This behavior was deprecated in 7.0
This behavior changed in 8.0