我有一个安装了WordPress的xampp。我也从http://download.eclipse.org/tools/pdt/updates/3.0/milestones/下载了PHP的Eclipse插件。我想在Eclipse(Indigo 3.7)中创建一个项目并调试我的PHP代码。有没有办法做到这一点?
我尝试了很多方法。最后,我决定使用XDebug。我通过修改php.ini文件来配置XDebug,并通过查看phpinfo()方法确认已经配置好。
我已经配置了Eclipse Indigo以使用XDebug作为我的PHP调试器,但是什么也没发生。
以下是我遵循的步骤:
1)在现有位置中创建了一个PHP项目 例如,我的项目在E:\ others \ xampp-win32-1.7.7-VC9 \ xampp \ htdocs中
2)修改php.ini文件以支持xdebug,并通过phpinfo()方法验证它已经配置好。
3)配置eclipse以使用XDebug作为PHP调试器。
以下是PHP调试的外观:
其次是PHP可执行文件:
接下来,我认为出了问题!配置PHP服务器。我读到我们需要指定路径映射等。我不知道如何做。
服务器的路径映射
只是想补充一下,当我尝试将index.php文件调试为PHP脚本时:它一直以消息“Launching: Launching delegate(24%)”启动,并且从未完成执行。
有人能建议缺少什么或需要纠正什么吗?
PHP.ini文件修改XDebug
[XDebug] zend_extension = “E:\ others \ xampp-win32-1.7.7-VC9 \ xampp \ php \ ext \ php_xdebug.dll” xdebug.remote_enable = 1 xdebug.remote_host = “127.0.0.1” xdebug.remote_port = 9000 xdebug.remote_handler = “dbgp” xdebug.remote_mode = “req”
谢谢, Adithya。
我尝试了很多方法。最后,我决定使用XDebug。我通过修改php.ini文件来配置XDebug,并通过查看phpinfo()方法确认已经配置好。
我已经配置了Eclipse Indigo以使用XDebug作为我的PHP调试器,但是什么也没发生。
以下是我遵循的步骤:
1)在现有位置中创建了一个PHP项目 例如,我的项目在E:\ others \ xampp-win32-1.7.7-VC9 \ xampp \ htdocs中
2)修改php.ini文件以支持xdebug,并通过phpinfo()方法验证它已经配置好。
3)配置eclipse以使用XDebug作为PHP调试器。
以下是PHP调试的外观:
![enter image description here](https://istack.dev59.com/oDVfc.webp)
![enter image description here](https://istack.dev59.com/QMaki.webp)
![enter image description here](https://istack.dev59.com/oNrYw.webp)
![enter image description here](https://istack.dev59.com/wzUrS.webp)
有人能建议缺少什么或需要纠正什么吗?
PHP.ini文件修改XDebug
[XDebug] zend_extension = “E:\ others \ xampp-win32-1.7.7-VC9 \ xampp \ php \ ext \ php_xdebug.dll” xdebug.remote_enable = 1 xdebug.remote_host = “127.0.0.1” xdebug.remote_port = 9000 xdebug.remote_handler = “dbgp” xdebug.remote_mode = “req”
谢谢, Adithya。