PHP Data Types
On 07/04/2012 OtherA data type is defined as a set of entities and the allowable operations on those values. Almost all programming languages explicitly include the notion of data type, though other languages may use different terminology.
And PHP has defined several data types.
Main PHP data types are:
- Boolean
- Integer
- String
- Array
- Object
- Resource
- NULL
Because PHP is a weakly-typed language all variables are writted with $ sign and without type before or after them. In order to fin a variable type, you can use var_dump($var) or gettype() function.