在 PhpStorm 中启用 Xdebug [英] Enabling Xdebug in PhpStorm
问题描述
我已经在 Paragon 服务器中安装了 Xdebug,我正在尝试在 PhpStorm 中启用它.但是当我按照步骤操作时,我无法正确验证安装.
我已将 php 安装目录中的 php.ini 文件更新为新版本的 Xdebug 3.0:
[Xdebug]zend_extension = C:\Laragon\bin\php\php-7.4.13-Win32-vc15-x64\ext\php_xdebug-3.0.0-7.4-vc15-x86_64.dllxdebug.mode=调试xdebug.client_port=9000
但我仍然在 PhpStorm 中不断收到验证错误.我还为 Xdebug 安装了 Chrome 扩展程序,但我似乎无法让它与 PhpStorm 一起使用.
Xdebug 3 将在 PhpStorm 2020.3 版本中完全支持,目前有 RC 版本,将在未来几天发布.
自 EAP #6 构建以来,它已经得到支持:查看此博客文章了解更多信息:
相同但使用 Xdebug 2.9.8 时(PHP 7.3,我仍然保留 Xdebug 2):
I have installed Xdebug in my Paragon server and I am trying to enable it in PhpStorm. But when I follow the steps I am unable to correctly validate the installation.
I have updated my php.ini file inside my php installation directory to the new version of Xdebug 3.0:
[Xdebug]
zend_extension = C:\Laragon\bin\php\php-7.4.13-Win32-vc15-x64\ext\php_xdebug-3.0.0-7.4-vc15-x86_64.dll
xdebug.mode=debug
xdebug.client_port=9000
But I still keep on getting the validation errors in PhpStorm. I have also installed the Chrome extension for Xdebug, but I cannot seem to get it to work with PhpStorm.
Xdebug 3 will be fully supported in PhpStorm 2020.3 version only, which currently has a RC build and will be released in next few days.
It is already supported since EAP #6 build: check this blog post for more info: https://blog.jetbrains.com/phpstorm/2020/11/phpstorm-2020-3-eap-6/
In PhpStorm 2002.2 and older you may just skip/ignore such Validation. It's there for info purposes only anyway (as it does not guarantee that the debug connection will actually work (e.g. due to firewall or other network related issues that this validation check does not check)).
P.S. Here is how that Validation screen looks in 2020.3 RC build for Xdebug 3 (PHP 8.0 here):
The same but when Xdebug 2.9.8 is used (PHP 7.3 where I still keep Xdebug 2):
这篇关于在 PhpStorm 中启用 Xdebug的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!