Site Admin
Joined: 13 Jul 2003 |
Posts: 8342 |
|
|
|
Posted: Tue May 23, 2006 3:41 pm |
|
|
|
|
|
If I understand you correct, you need a way to dump ALL variables, including a) globals, b) variables located in the outer scope and c) current local ones. In other words, if say function A is called from global context and it subseqently called function B and it means that you need all globals, all local variables in function A and all local variables in function B, right?
There is no such functions in PHP. With debugger you can dump them easily but still this info is available during debug session.
On the other hand, to me it does not look as a correct approach. Even if all and all the values are known, its still unclear what way the execution went on before. Said it, I'd recommend you to play with DebugBreak() function. Just add this call to the code point of the interest and it will start debugger when execution reaches it and you'll see not only variables but will be able to continue execution and/or modify values and see all the functions in the outer scope too (so-called Call Stack).
|
|