You can install XAMPP anywhere on your system, but for this tutorial, we will use c:\xampp as the installing directory, as its easier to type.
Install XAMPP to c:\xampp. If you want to run a web server, install the services. Its recommended if you want to test your site locally.
Download WinCacheGrind and install into its default location: c:\Program Files\WinCacheGrind\
Open C:\xampp\php\php.ini in a text editor. Find php_xdebug.dll:
in the file php.ini and make sure it is commented out (has a ; at the beginning of the line). If it isn't, it will cause problems later.
In the same file, find the line [Zend]:
and comment out all lines in that section with a single ; in front of each line. Xdebug cannot load if zend is operational.
In the next section [Xdebug]:
replace the entire section with the following:
;; Only Zend OR (!) XDebug zend_extension="\xampp\php\ext\php_xdebug-2.0.0-5.2.2.dll" xdebug.remote_enable=true xdebug.remote_host=127.0.0.1 xdebug.remote_port=9000 xdebug.remote_handler=dbgp xdebug.profiler_enable=1 xdebug.profiler_output_dir="\xampp\tmp"
The dll name changes occasionally, so if things aren't working, go to C:\xampp\php\ext\ and look for it, and copy its file name into the code above, replacing php_xdebug-2.0.0-5.2.2.dll then see if things work better.
1 - From PHP 5.3 onwards, you always need to use zend_extension and not
Finally, save the file php.ini and close it.
Go to the “Debugger” page from the menu Tools > Preferences, and change your settings to:
PHP Interpreter: c:\xampp\php\php-cgi.exe PHP Configuration File: c:\xampp\php\php.ini
Go to the “Profiler” page from the menu Tools > Preferences, and change your settings to:
WinCacheGrind - Viewer: c:\Program Files\WinCacheGrind\WinCacheGrind.exe Output directory: c:\xampp\tmp
Go to the “Run” page from the menu Tools > Preferences, and change your settings to:
PHP: c:\xampp\php\php-cgi.exe Configuration: c:\xampp\php\php.ini
Go to the “Localhost” page from the menu Tools > Preferences, and change your settings to:
Server path: http://localhost Local server path: c:\xampp\htdocs
If the configuration is done correctly, you're debug features should now be possible.