how is it possible to get the file and line where a class has been declared from and/or required?
Use Reflections to figure out where a class was declared:
$reflector = new ReflectionClass('Foobar');
echo $reflector->getFileName();
echo $reflector->getStartLine();
Use inclued
to figure out what was included where.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With