让PHPStorm与XDebug一起工作


Getting PHPStorm working with XDebug

我正在尝试让PHPStorm与Xdebug交谈,并且我运气很差。

这是我的设置:我有一个VM从我的本地机器共享我的php文件

我正在尝试遵循这个:http://blog.jetbrains.com/webide/2011/02/zero-configuration-debugging-with-xdebug-and-phpstorm-2-0/

我在php.ini

中添加了以下内容
zend_extension = /usr/lib64/php/modules/xdebug.so
xdebug.remote_connect_back = 1
xdebug.remote_enable = 1
xdebug.remote_handler = dbgp
xdebug.remote_mode = req
xdebug.remote_port = 9000
xdebug.remote_host = <my ip address>
xdebug.remote_log = /tmp/xdebug_remote.log

根据phpinfo(),我成功地运行了xdebug。

我打开脚本,打开监听器。但是当我讲到教程的"激活服务器上的调试器"部分时,事情就崩溃了。我下载了firefox插件来启动调试器(这个:https://addons.mozilla.org/en-US/firefox/addon/easy-xdebug/),单击图标来启动调试器,重新加载页面,但phpstorm没有找到它。我还尝试添加XDEBUG_SESSION_START=1作为POST值,但仍然没有运气。

我做错了什么?

您希望remote_host是vm在本地主机上看到的ip地址。这不是你从ISP那里得到的IP地址