3
votes

I've followed all the suggestions I've found, but I can't get PhpStorm working with PHP 7 and xDebug. I did have it working with PHP 5.6.

Xdebug is being loaded by PHP. I verified in the phpinfo() output. I've switched PhpStorm to use the PHP 7 version and it also lists the correct debugger as xdebug 2.4.0RC3

My xdebug settings are:

zend_extension = "/usr/local/opt/php70-xdebug/xdebug.so"
xdebug.remote_enable = 1
xdebug.remote_connect_back = 1
xdebug.remote_port = 9000
xdebug.remote_host = 127.0.0.1
xdebug.scream = 0
xdebug.cli_color = 1
xdebug.show_local_vars = 1
xdebug.idekey = PHPSTORM

I have the xdebug chrome extension installed, and it's correctly adding the Cookie:XDEBUG_SESSION=PHPSTORM;. I also enabled the debugging listener in PhpStorm.

Can anyone suggest what else I can do to try get my breakpoints to trigger?

2
I also had difficulties to get PHPSTORM working with XDebug (same versions). Finally the settings for the php.ini file from a netbeans tutorial did the trick for me. You may want to give it a try. - Milania
Thanks @Milania - but that didn't solve the problem. At least not from the xdebug.ini settings point of view. I did manage to get some logging from xdebug - so I can see it's def. working. It just seems that PhpStorm doesn't want to listen. It's weird that it was working fine for PHP 5.6. - joelataylor

2 Answers

4
votes

So, in my case, I found that by moving the port from 9000 to 9001 fixed. I guess something else was already using the default port. Problem solved!

0
votes

In case someone else lands here. For me the solution was that the path to the binary wasn't using "quotes".

[xdebug]
zend_extension = "C:\wamp\bin\php\php7.0.16\ext\php_xdebug-2.5.1-7.0-vc14-x86_64.dll"