PHP | is_int() Last Updated : 31 Oct, 2023 Comments Improve Suggest changes Like Article Like Report is_int() is an inbuilt function in PHP. The is_int() function is used to test whether the type of the specified variable is an integer or not. Syntax : boolean is_int($variable_name)Parameter: this function contains a single parameter $variable_name: the variable we want to check.Return value : it is a boolean function so returns TRUE when $variable_name is an integer, otherwise FALSE. PHP <?php $variable_name1 = 56; $variable_name2 = "xyz"; if (is_int($variable_name1)) { echo "$variable_name1 is Integer \n" ; } else { echo "$variable_name1 is not an Integer \n" ; } if (is_int($variable_name2)) { echo "$variable_name2 is Integer \n" ; } else { echo "$variable_name2 is not Integer \n" ; } ?> Output : 56 is Integer xyz is not Integer Reference : http://php.net/manual/en/function.is-int.php Comment More infoAdvertise with us Next Article PHP | is_int() S sid4321 Follow Improve Article Tags : Web Technologies PHP Similar Reads PHP | is_dir( ) Function The is_dir() function in PHP used to check whether the specified file is a directory or not. The name of the file is sent as a parameter to the is_dir() function and it returns True if the file is a directory else it returns False. Syntax: is_dir($file) Parameters Used: The is_dir() function in PHP 1 min read PHP | is_a() function The is_a() is a built-in function in PHP and is used to check whether a given object is of a given class or not. It also checks if the given class is one of the parents of the given object or not. Syntax: boolean is_a($object, $class) Parameters: This function accepts two parameters as shown in the 2 min read PHP isset() Function The isset() function in PHP checks whether a variable is declared and not NULL. It returns true if the variable exists and has a non-NULL value, and false otherwise, without modifying the variable. Syntaxbool isset( mixed $var [, mixed $... ] )Parameters: This function accept one or more parameter a 3 min read PHP is_integer() Function The is_integer() function is an inbuilt function in PHP that is used to check whether the type of a variable is an integer or not. This function is an alias of is_int() function. Syntax: bool is_integer(mixed $value) Parameters: This function accepts a single parameter $value that holds the value wh 1 min read PHP is_long() Function The is_long() function is an inbuilt function in PHP that is used to check whether the given value is a long integer or not. Syntax: bool is_long(mixed $value) Parameters: This function accepts a single parameter $value that holds the value which needs to check for a long integer. Return Value: This 1 min read PHP | is_real() Function The is_real() function is an inbuilt function in PHP which is used to check the given value is a real number or not. Syntax: bool is_real( mixed $var ) Parameters: This function accepts one parameter as mentioned above and described below: $var: It contains the value of variable that need to be chec 2 min read PHP | is_null() Function The is_null() function is an inbuilt function in PHP which is used to find whether a variable is NULL or not. Syntax: boolean is_null ( $var ) Parameters: This function accepts a single parameter as shown in above syntax and described below. $var: Variable to check if it is NULL or not. Return value 2 min read PHP | is_link( ) Function The is_link() function in PHP used to check whether the specified file is a symbolic link or not. The path to the file is sent as a parameter to the is_link() function and it returns TRUE if the filename exists and is a symbolic link, otherwise it returns FALSE. Syntax: is_link(file) Parameters Used 2 min read PHP | is_array() Function The is_array() is an inbuilt function in PHP. The is_array() function is used to check whether a variable is an array or not. Syntax: bool is_array($variable_name) Parameter: This function accept a single parameter as mentioned above and described below: $variable_name: This parameter holds the vari 2 min read PHP is_float() Function PHP is_float() is an inbuilt function in PHP. The is_float() function is used to find whether a variable is a float or not. Syntax: boolean is_float($variable_name) Parameter: This function contains a single parameter as shown in the above syntax and described below $variable_name: the variable we w 2 min read Like