I plan to use Netbeans IDE for my Moodle and WordPress PHP development. Netbeans is free, works on WAMP and is highly rated. Installation of WampServer is a bit tricky as you must absolutely follow the installation instructions to get it to work. Installation of Netbeans is straightforward.
My environment is as follows:
Windows 10 Pro 64bit WampServer 3.14, Apache 2.4.23, Php 7.0.10, Netbeans IDE 8.2
When I tried debugging with a breakpoint in my code, Netbeans would be waiting for Xdebug. It turns out that the php.ini settings related to Xdebug are crucial. I have mine as follows:
xdebug.remote_enable = 1
xdebug.profiler_enable = off
xdebug.profiler_enable_trigger = Off
xdebug.profiler_output_name = cachegrind.out.%t.%p
Here are the things I went through in addition to above to make it work:
- Ensured that
Netbeans->tools->options->phphad port 9000 and session ID set to
- Make sure that your WAMP server is running the same version of PHP as the version of xdebug file listed in zend_extension above, in php.ini. Also check that the path of zend_extention for the xdebug file is correct.
- I had xdebug.remote_host=127.0.0.1 but that didn’t work. Changing it to localhost made the connection. However, xdebug was not stopping at set breakpoints.
- I had to make
xdebug.remote_autostart=1in order for stopping at breakpoints to work.
- In php.ini I also set
output_buffering = Offnot sure if this is important.
- Ensured that