PHP Infinity Is Reachable¶
Infinite values are sometimes returned by PHP functions, such as log(0) or exp(PHP_INT_MAX). In these cases, beware and do not compare it directly with an integer as a positive is considered bigger than infinite. It is recommended to use the function is_finite.