note 43109 added to ref.classobj
| From: | brett_hegrxATxyahooxDOTxcom at rn2 dot php dot net | Date: | Wed, 09 Jun 2004 21:46:56 +0000 |
| Subject: | note 43109 added to ref.classobj | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-70603@lists.php.net to get a copy of this message | ||
// Useful function for determining if an object is either an
// instance or a subclass of a particular class.
function is_class($object,$class_name)
{
$parent = is_a($object, $class_name);
$child = is_subclass_of($object, $class_name);
return $parent xor $child;
}
----
Manual Page -- http://www.php.net/manual/en/ref.classobj.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+43109
Delete -- http://master.php.net/manage/user-notes.php?action=delete+43109&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+43109&report=yes
Search -- http://master.php.net/manage/user-notes.php