Php Is_Object Function
# PHP is_object() Function
[PHP Available Functions](#)
The **is_object()** function is used to check whether a variable is an object.
PHP Version: PHP 4, PHP 5, PHP 7
### Syntax
bool is_object ( mixed $var )
Parameter Explanation:
* $var: The variable to check.
### Return Value
Returns TRUE if the specified variable is an object, otherwise returns FALSE.
### Example
## Example
subjects); }$obj_name = new stdClass; $obj_name->subjects = Array('Google', 'Tutorial', 'Facebook'); var_dump(get_subjects(NULL)); var_dump(get_subjects($obj_name)); ?>
Output:
bool(false) array(3) { => string(6) "Google" => string(6) "Tutorial" => string(8) "Facebook"}
[PHP Available Functions](#)
YouTip