ThePsion5 Posted June 20, 2006 Share Posted June 20, 2006 Hi guys,I'm iterating through an array and removing objects from it that are one of three possible types. My question is the following: How can I test to see whether an object is an instance of a particular class without knowing anything about the object internally? I know that PHP probably has a function that returns the name of an object/class, but I can't find it. Any suggestions? Link to comment Share on other sites More sharing options...
justsomeguy Posted June 20, 2006 Share Posted June 20, 2006 http://www.php.net/manual/en/function.get-class.phphttp://www.php.net/manual/en/function.is-a.php Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now