If you have a number as a string is_int() won’t work. This will most probably clear your doubt.
<?php var_dump(is_int(12)); var_dump(is_int("12")); ?>
Output:
bool(true)
bool(false)
<?php var_dump(is_numeric(56)); var_dump(is_numeric("56")); ?>
Output:
bool(true)
bool(true)
Happy Programming,