What is the use of function is_object? Just as the name suggests is it used for checking whether the given argument is a object. What is the return value of this PHP function?
Printable View
What is the use of function is_object? Just as the name suggests is it used for checking whether the given argument is a object. What is the return value of this PHP function?
Returns TRUE if var is an object, FALSE otherwise.
If you want ot more clarification goto the following site....
URL: [url=http://in2.php.net/is_object]PHP: is_object - Manual[/url]
------------------
suresh
Ramasri,
As u said, the name suggests.
If I ask you, if something [B]is[/B] an [B]object[/B], you would say 'Yes' or 'No', but the function says (returns) 'True' or 'False'
if some object say [COLOR="Blue"]obj1[/COLOR] of class "[COLOR="Blue"]class1" [/COLOR] is created, to know whether, the checking object(obj1 or other object) is an instance of a class of class "[COLOR="Blue"]class1[/COLOR]" we can use is_object(obj1)