NetBeans 11.3 等待连接到 Xdebug
我使用的是 Windows 10、NetBeans 11.3、PHP7.4.9、Apache/2.4.46 (Win64)、XAMPP v3.2.4 和 MySQL。
我的 php.ini 文件具有以下设置:
output_buffering=off
[XDebug]
zend_extension = "c:\xampp\php\ext\php_xdebug-2.9.7-7.4-vc15-x86_64.dll"
xdebug.remote_autostart = 1
xdebug.profiler_append = 0
xdebug.profiler_enable = 0
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "c:\xampp\tmp"
xdebug.remote_enable = 1
xdebug.idekey="netbeans-xdebug"
xdebug.remote_handler = "dbgp"
xdebug.remote_host = "localhost:81"
xdebug.remote_log = "c:\xampp\tmp\xdebug.txt"
xdebug.remote_port = 9000
xdebug.trace_output_dir = "c:\xampp\tmp"
xdebug.remote_cookie_expire_time = 36000
NetBeans 配置:
Debugger port: 9000
Session ID: netbeans-xdebug
Stop at first line: Checked
All other options are unchecked
当我单击调试图标 (Ctrl + F5) 时,它会卡在“等待连接 (netbeans-xdebug)”上,同时完全显示页面无需在断点处停止。
I am using Windows 10, NetBeans 11.3, PHP7.4.9, Apache/2.4.46 (Win64), XAMPP v3.2.4 and MySQL.
My php.ini file has the following settings:
output_buffering=off
[XDebug]
zend_extension = "c:\xampp\php\ext\php_xdebug-2.9.7-7.4-vc15-x86_64.dll"
xdebug.remote_autostart = 1
xdebug.profiler_append = 0
xdebug.profiler_enable = 0
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "c:\xampp\tmp"
xdebug.remote_enable = 1
xdebug.idekey="netbeans-xdebug"
xdebug.remote_handler = "dbgp"
xdebug.remote_host = "localhost:81"
xdebug.remote_log = "c:\xampp\tmp\xdebug.txt"
xdebug.remote_port = 9000
xdebug.trace_output_dir = "c:\xampp\tmp"
xdebug.remote_cookie_expire_time = 36000
NetBeans configuration:
Debugger port: 9000
Session ID: netbeans-xdebug
Stop at first line: Checked
All other options are unchecked
When I click on debugging icon (Ctrl + F5) it gets stuck on "waiting for connection (netbeans-xdebug)" while shows the page completely without stopping at the break points.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
xdebug.remote_host = "localhost:81"
肯定不正确。remote_host
应具有运行 IDE 的 IP 地址或主机名的值。这可能只是localhost
。您还应该升级到 Xdebug 3.1,它具有更好的日志记录功能,可以通过它的
xdebug_info 排除连接错误()
函数,以及xdebug.log
和xdebug.log_level
设置。但请务必参阅升级指南,因为某些设置名称已更改。您可能只需要:
xdebug.remote_host = "localhost:81"
is certainly not correct. Theremote_host
should have the value of the IP address or hostname where your IDE runs. This is likely justlocalhost
.You should also upgrade to Xdebug 3.1, which has much better logging functionality for troubleshooting connection errors through it's
xdebug_info()
function, andxdebug.log
andxdebug.log_level
settings.Please do refer to the upgrade guide though, as some setting names have changed. You would likely only need: