To explicitly convert a value to integer, use either the (int) or (integer) casts.
In most cases the cast is not needed, since a value will be automatically converted if an operator, function or control structure requires an integer argument.
A value can also be converted to integer with the intval() function.
If a resource is converted to an integer, then the result will be the unique resource number assigned to the resource by PHP at runtime.
FALSE will yield 0 (zero), and TRUE will yield 1 (one).
When converting from float to integer, the number will be rounded towards zero.