Php is nan
From w3cyberlearnings
Contents |
PHP function is_nan
This function checks whether a given value is a number.
Syntax is_nan
X is a value to check
is_nan(X);
Return
Return true when the value is not a number, otherwise it returns nothing.
Example 1
<?php echo "Check 1: "; echo is_nan(acos(9)); echo "<br/>"; echo "Check 2:"; echo is_nan(log(2)); echo "<br/>"; ?>
Output
Check 1 is not a number.
Check 1: 1 Check 2: