如何让Xdebug在Mac上运行 [英] How to get Xdebug to work on a Mac

查看:187
本文介绍了如何让Xdebug在Mac上运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我花了很多时间在没有最终产品上.

I have spent a lot of time on this with no end product.

  1. 已安装MAMP.
  2. 找到"make"(已安装在其他文件夹中)
  3. 安装了缺少的autoconf,所以我可以运行phpize
  4. 根据以下内容下载,编译和安装xdebug:

http://www.xdebug.org/find-binary.php

  1. 进行了必要的更改以更正php.ini.
  2. 重新启动MAMP-但phpinfo()不显示xdebug.

无论我对/Applications/MAMP/conf/php5.3/php.ini中的php.ini文件做什么,都不会改变.该站点仍然可以正常加载.即使我完全否定它.但这就是phpinfo()所显示的正在加载.

No matter what I do to the php.ini file located at /Applications/MAMP/conf/php5.3/php.ini, nothing changes. The site still loads fine. Even if I nuke it completely. Yet that is what phpinfo() shows it is loading.

我俯瞰什么?

php.ini

[xdebug]
zend_extension=/Applications/MAMP/bin/php5.3/lib/php/extensions/no-debug-non-zts-20090626/xdebug.so
xdebug.remote_enable=1
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.remote_autostart=1 

推荐答案

只是指出显而易见的一点,但我一直在浪费时间.在apache2环境中,请记住重新启动apache2才能使更改生效.

Just to point out the obvious, but one that I keep throwing away time on; in an apache2 environment remember to restart apache2 for the changes to take effect.

sudo apachectl restart

这篇关于如何让Xdebug在Mac上运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆