check type in php
gettype ( mixed $var ) : string
Source: www.php.net
php get variable type
<?php
$a = 3;
echo gettype($a) . "<br>";
$b = 3.2;
echo
gettype($b) . "<br>";
$c = "Hello";
echo gettype($c) . "<br>";
$d = array();
echo
gettype($d) . "<br>";
$e = array("red", "green", "blue");
echo
gettype($e)
. "<br>";
$f = NULL;
echo gettype($f) . "<br>";
$g = false;
echo gettype($g) . "<br>";
?>
Source: www.w3schools.com
find type in php
gettype($u)
Share This
0Shares
Be the first to comment