Xdebug not connecting
System:
Phpstorm 2019.1
Lubuntu 18.04
Php 7.2
Xdebug 2.6
Apache2
Steps taken:
* Check the php 7.2 config file path: /etc/php/7.2/cli/php.ini
* Verify installation of Xdebug: It is seen in terminal (php --version) and in a local file that has phpinfo();
* Add these lines to both ( /etc/php/7.2/cli/php.ini ) and ( /etc/php/7.2/apache2/php.ini ):
zend_extension="/usr/lib/php/20170718/xdebug.so"
xdebug.collect_vars=1
xdebug.remote_autostart=1
xdebug.remote_enable=1
xdebug.remote_port=9000
* systemctl restart apache2 (for next step).
* Validate local server configuration within phpstorm. All green marks (full validation)
* install chrome debug extension (Xdebug Helper). Mark project site as "debug" in the extension's drop down menu.
* Click the phone icon in the top right of Phpstorm to enable listening for Xdebug on port 9000
* Restart phpstorm.
If possible I would like to pay for a teamviewer session to solve this problem. I have not been able to solve it here (before). If you can not do this please continue to assist me here.
Please sign in to leave a comment.
The debugger popped open on localhost/info.php
It did not open or show data on localhost/wptest2/<subfiles>
localhost/wptest2 is specifically set to "DEBUG" on the chrome extension.
At least we have progress. Why can't the debugger read from my test wordpress site?
Please see the bottom left and also the terminal message. What causes these errors?
I am waiting for help with this
Could you please show "File | Settings | Languages & Frameworks | PHP | Servers" window? Do you have any mappings set up there?
That screen is totally empty, I guess there are no mappings
Sorry for the obvious comment, but would it be possible to configure these?
https://www.jetbrains.com/help/phpstorm/servers.html
Also, probably you have already seen it but I would recommend checking this part of the guide:
https://www.jetbrains.com/help/phpstorm/zero-configuration-debugging.html
Ok, I have set a mapping for Xdebug to localhost:80.
The debugger pops open in Phpstorm, I think when I reload the page to the project site.
The issue is the loading never stops.
What could be blocking the loading from completing?
> I am waiting for help with this
Please use Help > Contact Support instead. Forums are not fully-fledged support portals.
The problem is: your project is at /var/www/html/wptest2 while you're trying to load the page located at /var/www/html/ (1 level up). Try to place info.php at /var/www/html/wptest2 instead.
Also try uncommenting "xdebug.remote_host=127.0.0.1" entry in your .ini file.