Netbeans not connecting to xdebug on MAMP, showing “waiting for connection”

I am trying to set up xdebug so that I can debug my php wordpress project. I am using MAMP to run the project and have configured xdebug in the php.ini file as follows.

zend_extension="/Applications/MAMP/bin/php/php5.5.26/lib/php/extensions/no-debug-non-zts-20121212/xdebug.so"

debug.default_enable=1

xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_host=localhost
xdebug.idekey=“netbeans-xdebug”
xdebug.remote_port=9001
xdebug.remote_autostart=1

This is working as I can see xdebug in my phpinfo().

Read More

phpinfo

I’m now trying to connect netbeans to xdebug so that I can actually debug my code. I have pointed netbeasns to xdebug-netbeans at port 9001. I then try to debug my project but it just gets stuck on

waiting for connection(netbeans-xdebug)

It has worked for me twice (it went to debugging mode) but after clicking continue (it stopped on the first line in index.php) it wouldn’t work anymore and the page wouldn’t load. I then tried to reload the debugging but it went back to waiting for connection.

Any idea what’s wrong?

Thanks.

Related posts

1 comment

  1. In the php.ini file

    implicit_flush = On
    

    (by default it will be Off).

    Here PHP will tell the output layer to flush itself automatically after every output block.

    I Hope this helps.

Comments are closed.