is it an array, or is it an integer, or is it numeric : is_numeric « Reflection « PHP






is it an array, or is it an integer, or is it numeric

 
<?php
     $item = 43;
     echo "\$item is of type array: ".is_array($item)."<br />";
     echo "\$item is of type integer: ".is_integer($item)."<br />";
     echo "\$item is numeric: ".is_numeric($item)."<br />";
?>
  
  








Related examples in the same category

1.function is_numeric() checks if the value passed as the argument is numeric