title: "is_int" is not working properly?
body: <p>I am trying to check, Input is an integer, float or string. This program gives an error on negative inputs, I don't understand why this happen. When i check inputs with "ctype_digit()", is_int section escaped.</p>
  
  <pre><code>&lt;?php
  $var=fgets(STDIN);
  if(is_numeric($var))
  {
      //print "$var";
     if(ctype_digit($var) || is_int($var)){
         print "$var";
         print "This type of input is Integer";
     }
     else{
         //print "$var";
         print "This type of input is Float";
     }
  }
  else{
      print "This type of input is String";
  }
  ?&gt;
  </code></pre>