List of Include files?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
gilf
Forum Newbie
Posts: 3
Joined: Fri Feb 06, 2009 5:33 am

List of Include files?

Post by gilf »

Is there any way I can get a list of the files that I have included in a php script.

We have a large and complex number of PHP pages which we use, what I need is some way to print out a list of the pages which I have included during the execution of a php script. So lets say I have a main page which then includes another page which then includes 2 other pages, what I need is to be able to call a command and get a list of all the files that were included.

Obviosuly I could just add some sort of array to hold the values as I go along but that would mean changing literally thousands of pages of code.

Any ideas?

Another thing I'd like to add to that would be to get the run time of when the page was included.
User avatar
requinix
Spammer :|
Posts: 6617
Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA

Re: List of Include files?

Post by requinix »

Hmm...

As for time they were included: no. That you'd have to do yourself.
gilf
Forum Newbie
Posts: 3
Joined: Fri Feb 06, 2009 5:33 am

Re: List of Include files?

Post by gilf »

Thanks for that.

The Timing was the cherry on top but the list of includes will help a lot.
gilf
Forum Newbie
Posts: 3
Joined: Fri Feb 06, 2009 5:33 am

Re: List of Include files?

Post by gilf »

OK me again.....

Any idea how I could get a list of the objects a PHP page has created? So similar to the above but for objects, doesn't seem to be a standard on but I would imagine there could be a more techincal way to get the information.


Thanks in advance
Post Reply