for instance
I've a class called Ent, and have an object $ent
how can I get the class Ent out of $ent?
$ent = new Ent()
You can use get_class($ent)
get_class - Returns the name of the class of an object
Reference php docs
You could get get_class().
Watch out though, if your calling it on a variable that might not be an object it will throw a warning.
if(is_object($ent))
{
$class = get_class($ent);
}