Manejo de variables
gettype()
";
echo "\$texto = " . gettype($texto) . "
";
echo "\$entero = " . gettype($entero) . "
";
echo "\$flotante = " . gettype($flotante) . "
";
echo "\$arreglo = " . gettype($arreglo) . "
";
echo "\$nulo = " . gettype($nulo) . "
";
// Si error_reporting = E_ALL esto arroja una notificacion
echo "\$noDefinida = " . gettype($noDefinida) . "
";
// Esto no es recomendable
if (gettype($nulo) == "NULL")
{
echo "gettype() - nulo !
";
}
// Esta es la manera recomendada
if (is_null($nulo))
{
echo "is_null() - nulo !";
}
?>