I just wonder why php have a function like is_int()
. Documentation says that
To test if a variable is a number or a numeric string (such as form input, which is always a string)
I am sure that no one will ever have to check the type of a variable that is statically assigned. So someone please tell me will there be any situation, where the function is_int()
really useful ?