PHP » GoLang |
login |
register |
about
|
is_subclass_of(PHP 4, PHP 5, PHP 7) is_subclass_of — Checks if the object has this class as one of its parents or implements it Description
Checks if the given Parameters
Return Values
This function returns Changelog
Examples
Example #1 is_subclass_of() example
<?php The above example will output: yes, $WFC is a subclass of WidgetFactory no, $WF is not a subclass of WidgetFactory yes, WidgetFactory_Child is a subclass of WidgetFactory
Example #2 is_subclass_of() using interface example
<?php The above example will output: Yes, $my_object is a subclass of MyInterface Yes, MyClass is a subclass of MyInterface Notes
See Also
|
more
Recently updated
more
Most requested
more
Last requests
|