PHP profiling with Xdebug

Best is to enable Xdebug with a trigger, that is added by a .htaccess. With this method I can profile a single application within my development environment.

Xdebug settings

To make use of Xdebug I need to add a GET, POST or COOKIE variable with the name XDEBUG_PROFILE.

I use a .htaccess in my project root to add the specified GET parameter.

.htaccess Example

 Analyzing the Output

On my Windows 7 maschine I use WinCacheGrind to analyze the profiler output.