Adding Debugger Support to PhpStorm Project
I'm having trouble connecting the debugger to PhpStorm 2016.3. I've downloaded Xdebug and entered the php.ini directives which has successfully resulted in the banner with Xdebug 2.5.0rc1 being displayed when I run php -v. The problem I'm having is starting a debugging session. I've managed to enable on demand debugging and jit using the additional configuration directives in the IDE, but when I click on debug I get a debug window, but with no variables in the frame and I'm also unable to set breakpoints. What could be the problem?
Many thanks in advance.
Julian
Please sign in to leave a comment.
https://intellij-support.jetbrains.com/hc/en-us/community/posts/205972064-PHPSTORM-not-receiving-debug-connection-from-xdebug-2-5
@Andriy Bazanov: Thank-you for the link to the other thread. I've downgraded Xdebug to 2.4.1 and I have the following Xdebug section in the top of my php.ini file:
[xdebug]
zend_extension="C:\Program Files\php\ext\php_xdebug.dll"
xdebug.remote_enable=1
xdebug.remote_port=9000
xdebug.remote_host=localhost
xdebug.remote_idekey="PHPSTORM"
xdebug.profiler_enable=1
xdebug.profiler_output_dir="C:\Users\Julian\.profiler"
xdebug.remote_autostart=1
I hope this helps someone who is also having problems.
Julian
>xdebug.profiler_output_dir="C:\Program Files\php\profiler"
I do not recommend using paths in "C:\Program Files" for outputting data (of any kind). Such paths should be writeable by installers and Windows OS itself and not random app. By default, with UAC enabled, that path is protected from such modifications.
Better create some "C:\PHP_Temp\profiler" or similar folder for that
Or even better "C:\Users\Julian\.profiler".
EDIT: Changed original post to reflect this change. -Julian