PHP is_long() Function

The PHP is_long () function in PHP is used to find whether a variable is an integer or not. It returns a Boolean value true if the parameter var is integer else it returns false.

This function is an alias of is_int() function.

Syntax

is_long( mixed $var ) 

Parameter

var(required)- This parameter represents the value to check.

Return

This function returns a Boolean value TRUE if the parameter var is an integer, else it returns FALSE.

Example 1

 

Output

bool(false)
bool(false)
bool(false) 

Example 2

 

Output

2132 is an integer value. 

Example 3

 

Output

The var is integer