在Mac上的Eclipse中安装Xdebug

时间:2014-02-27 12:41:37

标签: php eclipse macos xdebug

我整天都在努力让Xdebug在Mac上运行Eclipse Helios for php。我已经重写了我的php.ini文件,该文件位于/Applications/MAMP/bin/php/php5.5.3/conf/php.ini,如下所示;

zend_extension="/Applications/MAMP/bin/php/php5.5.3/lib/php/extensions/no-debug-non-zts-     20121212/xdebug.so" 
xdebug.remote_enable = On
xdebug.remote_handler = dbgp
xdebug.remote_mode = req
xdebug.remote_host = localhost
xdebug.remote_port = 9000
xdebug.idekey =
xdebug.profiler_enable = On
xdebug.profiler_output_dir = “/Applications/MAMP/tmp/xdebug/”

另外,我有Komodo-PHPRemoteDubgging并替换了/Applications/MAMP/bin/php/php5.5.3/lib/php/extensions/no-debug-non-zts-20121212/xdebug.so中的xdebug.so文件。 / p>

如果我查看phpInfo(),我可以找到术语Xdebug。

但是,当我尝试在调试模式下在eclipse上运行我的Web应用程序时,它会停止在57%。

有人可以帮我解决这个问题吗?

1 个答案:

答案 0 :(得分:0)

好的,我想我得到了自己问题的答案。我已使用以下内容替换了php.ini文件中[xdebug]下的内容;

[Xdebug的]

zend_extension="/Applications/MAMP/bin/php/php5.5.3/lib/php/extensions/no-debug-non-zts-20121212/xdebug.so"
xdebug.remote_enable=On
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_autostart=Off
xdebug.profiler_enable = On
xdebug.profiler_dir = “/Applications/MAMP/tmp”
xdebug.collect_vars=on
xdebug.collect_params=4
xdebug.dump_globals=on
xdebug.dump.GET=*
xdebug.dump.POST=*
xdebug.show_local_vars=on

我不知道有什么区别,但现在它似乎终于有用了。