PHP code of check if given variable is an array PHP
Posted On at by milanIn php you can check if variable which you are going to use is as array or not. Its done using is_array() function. Which returns TRUE or FALSE
Here are some implementation examples.
' : 'no its not an array' ?>
OR
$res=is_array($variable);
if($res)
{
echo "its an array";
//Some other code
}
else
{
echo "its not an array ";
//some other code
}
?>