note 3173 deleted from Classes and Objects by jmoore
| From: | jmoore@php.net | Date: | Sat, 10 Feb 2001 23:30:16 +0000 |
| Subject: | note 3173 deleted from Classes and Objects by jmoore | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-10890@lists.php.net to get a copy of this message | ||
is_object() will tell you if a variable is pointing to an object or not.
However, I didn't find a built-in constant that means "no object" - like
<code>null</code> in Java or C++. My workaround is this:
<pre>define("null", 0)</pre>Obviously, since null is an int, is_object(null)
will return false.