I would like the code below to return 'Int' the first time and 'Not int' the second time. Unfortunately it returns 'Not int' twice instead.
How can I fix this?
<?php
$test1='1';
if(is_int($test1)){
echo "Int";
}else{
echo "Not int";
}
echo "\n";
$test2='1a';
if(is_int($test2)){
echo "Int";
}else{
echo "Not int";
}
?>