xampp 中的 xdebug 在 netbeans 上不起作用

发布于 2024-11-10 04:31:38 字数 1450 浏览 3 评论 0 原文

我尝试配置 xdebug 但不起作用我使用:

XAMPP 1.7.4  , Netbeans 7.0
Xdebug installed: 2.1.0rc1 
Server API: Apache 2.0 Handler
Windows: yes - Compiler: MS VC6 - Architecture: x86 
Zend Server: no 
PHP Version: 5.3.5 
Zend API nr: 220090626 
PHP API nr: 20090626 
Debug Build: no 
Thread Safe Build: yes 
Configuration File Path: C:\WINDOWS 
Configuration File: C:\xampp\php\php.ini
Extensions directory: C:\xampp\php\ext 

php.ini

zend_extension = "C:\xampp\php\ext\php_xdebug.dll"
xdebug.collect_includes = 1
xdebug.collect_params = 1
xdebug.collect_return = 1
xdebug.default_enable = 1
xdebug.extended_info = 1
xdebug.profiler_append = 0
xdebug.profiler_enable = 1
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "C:\xampp\tmp"
xdebug.remote_autostart = 1
xdebug.remote_enable = 1
xdebug.remote_handler = "DBGp"
xdebug.remote_host = "localhost"
xdebug.remote_port = 9000

现在的问题:

菜单附加调试器仍然被禁用或变灰。

当我尝试调试时,断点永远不会被命中。脚本像平常一样运行。

以下是我点击调试主项目时得到的URL:

http://localhost/index.php?XDEBUG_SESSION_START=netbeans-xdebug < /p>

当我关闭浏览器调试器不会停止。它显示等待连接状态。

当我单击 NetBeans 中的停止调试按钮时,会出现一个消息框 在几秒钟内未检测到来自 xdebug 的连接 xdebug 未配置或 xdebug 未安装。

请指导我解决上述问题并调试项目。

I try to config xdebug but doesn't work I use:

XAMPP 1.7.4  , Netbeans 7.0
Xdebug installed: 2.1.0rc1 
Server API: Apache 2.0 Handler
Windows: yes - Compiler: MS VC6 - Architecture: x86 
Zend Server: no 
PHP Version: 5.3.5 
Zend API nr: 220090626 
PHP API nr: 20090626 
Debug Build: no 
Thread Safe Build: yes 
Configuration File Path: C:\WINDOWS 
Configuration File: C:\xampp\php\php.ini
Extensions directory: C:\xampp\php\ext 

And php.ini:

zend_extension = "C:\xampp\php\ext\php_xdebug.dll"
xdebug.collect_includes = 1
xdebug.collect_params = 1
xdebug.collect_return = 1
xdebug.default_enable = 1
xdebug.extended_info = 1
xdebug.profiler_append = 0
xdebug.profiler_enable = 1
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "C:\xampp\tmp"
xdebug.remote_autostart = 1
xdebug.remote_enable = 1
xdebug.remote_handler = "DBGp"
xdebug.remote_host = "localhost"
xdebug.remote_port = 9000

Now the problems:

Menu attach Debugger is still disabled or grayed out.

When I try to debug the break point is never hit. Scripts run like a normal.

Following is the URL of I get when I click Debug main project:

http://localhost/index.php?XDEBUG_SESSION_START=netbeans-xdebug

When I close the browser debugger does not stop. It shows the waiting for connection status.

When I click the stop debugging button in NetBeans gives a messagebox There is no connection from xdebug detected with in some seconds xdebug is not configured or xdebug is not installed.

Please guide me to resolve the above mentioned issues and debug the project.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

め七分饶幸 2024-11-17 04:31:38

首先,您可以在 http://localhost/xampp/index.php 中看到 xdebug 吗?如果不是,那么您可能没有编辑正确的 php.ini 文件?看起来 XAMPP 正在使用 php.ini 文件:

c:\xampp\apache\bin\php.ini

在该文件中输入 xdebug 的配置,重新启动 Apache,您应该能够连接。

我无需对 Netbeans 进行任何更改即可使其正常工作。

屏幕截图在这里: http://rudyegenias .wordpress.com/2011/07/03/xampp-xdebug-xdebug-not-showing-in-phpinfo/

First are you able to see xdebug in http://localhost/xampp/index.php ? If NOT then probably you are NOT editing the right php.ini file? Seems like XAMPP is using the php.ini file in:

c:\xampp\apache\bin\php.ini

Enter your configuration for xdebug in that file, restart Apache and you should be able to connect.

There was no need for me to change anything in Netbeans to get it to work.

Screenshots here: http://rudyegenias.wordpress.com/2011/07/03/xampp-xdebug-xdebug-not-showing-in-phpinfo/

叹沉浮 2024-11-17 04:31:38

<强>?在 Netbeans 上使用 XDebug XAMPP

  • 使用 http://xdebug.org/wizard.php 来检查您的系统并下载最好的xdebug.dll

  • 将该 .dll 放入 C:/xampp/php/ext

  • 编辑 C:/xampp/php/php.ini添加以下

[XDebug]
zend_extension = C:\xampp\php\ext\php_xdebug-2.2.3-5.5-vc11.dll
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.show_local_vars=on
xdebug.output_buffering=off

  • 重新启动 Apache Web 服务器

我一直在努力解决很多其他设置,但这是最好的方法

? to use XDebug on Netbeans & XAMPP

  • use http://xdebug.org/wizard.php to inspect your system and download best xdebug.dll

  • place that .dll in C:/xampp/php/ext

  • edit C:/xampp/php/php.ini adding following

[XDebug]
zend_extension = C:\xampp\php\ext\php_xdebug-2.2.3-5.5-vc11.dll
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.show_local_vars=on
xdebug.output_buffering=off

  • restart Apache web server

I've struggled with a lot of other setting but this is best to do the job

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文