I using XAMPP and I have configure it in order to have virtual hosts for each project I create localy.
In my php.ini I have enabled xdebug, and my scripts are working properly. I mean that any time there is a warning, notice, error, are reported by the xdebug.
Now I would like to enable the Xdebug profiler, and I have make the following changes into my php.ini in order to allow the Xdebug profiler to generate the log file:
; xdebug.profiler_enable
; Type: integer, Default value: 0
; Enables Xdebugs profiler which creates files in the profile output directory. Those files can be
; read by KCacheGrind to visualize your data. This setting can not be set in your script with ini_set
; ().
xdebug.profiler_enable = 1
; xdebug.profiler_output_dir
; Type: string, Default value: /tmp
; The directory where the profiler output will be written to, make sure that the user who the PHP
; will be running as has write permissions to that directory. This setting can not be set in your
; script with ini_set().
xdebug.profiler_output_dir ="D:\Web Development Projects\Profile"
I restart my Apache, but still when I run my scripts there is no file generated in folder Profile.
Is there anything else I have to do ?
I have read that in order to enable the Profiler : http://xdebug.org/docs/profiler
After some research, I add that code at the end of the index.php in a WordPress installation I have in my server:
echo xdebug_get_profiler_filename();
After I run my WordPress, at the footer I get that result:
D:/Web Development Projects/Profile/xdebug_profile._::1320916508_018294
but when I go to the folder
D:/Web Development Projects/Profile/
the file is not appeared there ? Any idea ?
The problem solved !
The problem generated because of the log file name.
I just changed it to:
xdebug.profiler_output_name = "callgrind.out.%t-%s"
and working properly !