Manejo de variables
settype()
Antes de setype()
";
echo "\$boleano = $boleano = " . gettype($boleano) . "
";
echo "\$texto = $texto = " . gettype($texto) . "
";
echo "\$texto2 = $texto2 = " . gettype($texto2) . "
";
echo "\$entero = $entero = " . gettype($entero) . "
";
echo "\$flotante = $flotante = " . gettype($flotante) . "
";
echo "\$arreglo = $arreglo = " . gettype($arreglo) . "
";
echo "\$nulo = $nulo = " . gettype($nulo) . "
";
settype($boleano,"string");
settype($texto,"integer");
settype($texto2,"integer");
settype($entero,"array");
settype($flotante,"integer");
// Si error_reporting = E_ALL esto arroja una notificacion
settype($arreglo,"string");
settype($nulo,"float");
echo "
Despues de setype()
";
echo "\$boleano = $boleano = " . gettype($boleano) . "
";
echo "\$texto = $texto = " . gettype($texto) . "
";
echo "\$texto2 = $texto2 = " . gettype($texto2) . "
";
echo "\$entero = $entero = " . gettype($entero) . "
";
echo "\$flotante = $flotante = " . gettype($flotante) . "
";
echo "\$arreglo = $arreglo = " . gettype($arreglo) . "
";
echo "\$nulo = $nulo = " . gettype($nulo) . "
";
?>