I'm currently working on big crm (PHP) application. My boos want me to improve functionality. After 2 days of nothing I'm desperated
tracking the code execution
Moderator: General Moderators
tracking the code execution
Hi
I'm currently working on big crm (PHP) application. My boos want me to improve functionality. After 2 days of nothing I'm desperated
. I'm wondering if ther is a tool(or application) that let me to track which method after which is executing from start to result on screen.
I'm currently working on big crm (PHP) application. My boos want me to improve functionality. After 2 days of nothing I'm desperated
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
If you have an idea you can track method calls with Mocks but if you already have the complex system built this will be dfificult to tailor in now.
Xdebug is very nice. If you have the ability to install extensions this is well worthwhile. It's useful for other things such as looking for areas which consume memory too.
Xdebug is very nice. If you have the ability to install extensions this is well worthwhile. It's useful for other things such as looking for areas which consume memory too.
What I intend to get is something like this:
I want to know exactly what methods and after what (or from which interior) are executed.
Let's assume I have $App->Run()
And method Run execute $someObject->initialize() , and inside initialize() is other called $this->setVars(),
at the end inside $App->Run() $this->Display() is executed and we se the generated site in webbrowser.
So I want to be able to trace the path of execution in some nice way for example a raport formated for example:
$App->Run()
$someObject->initialize()
$this->setVars()
$this->Display()
Is this debbuger (mentioned in previous posts) able to do sth like this????
I want to know exactly what methods and after what (or from which interior) are executed.
Let's assume I have $App->Run()
And method Run execute $someObject->initialize() , and inside initialize() is other called $this->setVars(),
at the end inside $App->Run() $this->Display() is executed and we se the generated site in webbrowser.
So I want to be able to trace the path of execution in some nice way for example a raport formated for example:
$App->Run()
$someObject->initialize()
$this->setVars()
$this->Display()
Is this debbuger (mentioned in previous posts) able to do sth like this????
Well I have installed Xdebug installation was successful i've got all additional info running phpinfo();.
I have also insert this to my php.ini
[debbugger]
xdebug.remote_enable=true
xdebug.remote_host=127.0.0.1
xdebug.remote_port=46019
xdebug.remote_handler=gdb
xdebug.profiler_enable=true
xdebug.profiler_enable_trigger=1
xdebug.profiler_output_dir=/var/www/profilersDir
xdebug.remote_autostart=true
xdebug.auto_trace=true
xdebug.trace_output_dir = /tmp/tmp2
When I made error in script I get info from stacktrace and table with info so I know that Xdebug is working properly.
What is bothering me is that I dont know how to turn on profiler to dispalay info about functions.
How to get this done?? And where I'm suppose to use xdebug_start_profiling() (I've tried inside script but it said that undefined function)
Is there any application that support this??
I have also insert this to my php.ini
[debbugger]
xdebug.remote_enable=true
xdebug.remote_host=127.0.0.1
xdebug.remote_port=46019
xdebug.remote_handler=gdb
xdebug.profiler_enable=true
xdebug.profiler_enable_trigger=1
xdebug.profiler_output_dir=/var/www/profilersDir
xdebug.remote_autostart=true
xdebug.auto_trace=true
xdebug.trace_output_dir = /tmp/tmp2
When I made error in script I get info from stacktrace and table with info so I know that Xdebug is working properly.
What is bothering me is that I dont know how to turn on profiler to dispalay info about functions.
How to get this done?? And where I'm suppose to use xdebug_start_profiling() (I've tried inside script but it said that undefined function)
Is there any application that support this??
Well you are right I forgot set up the rights for writing that why i didint se the result in directory. But what to do if I want to print result on screen immediately.
Or How to get this data displayed in a good format (in table??)
I found that KcacheGrid will retrive it well but is there other tool because I'm not going to install KDE just for one tool.
Or How to get this data displayed in a good format (in table??)
I found that KcacheGrid will retrive it well but is there other tool because I'm not going to install KDE just for one tool.
Last edited by uki on Fri Sep 08, 2006 6:12 pm, edited 1 time in total.