php max sierra 上的 xdebug 不工作

php xdebug on max sierra not working

在 Mac 塞拉利昂:

我已经安装了 php 7.1,并通过以下方式安装了 xdebug:

brew 安装php71-xdebug

Xcode 是 8.0

php-v 无法加载 Xdebug - 它已经加载 PHP 7.1.0RC3 (cli)(内置:2016 年 10 月 2 日 01:05:16)(NTS) 版权所有 (c) 1997-2016 PHP 集团 Zend Engine v3.1.0-dev,版权所有 (c) 1998-2016 Zend Technologies 使用 Xdebug v2.4.0,版权所有 (c) 2002-2016,Derick Rethans

使用 phpinfo() 我找不到任何显示 xdebug

的文本

php.ini 文件我已经尝试了几种变体:并重新启动了 apache

[xdebug]
zend_extension="/usr/local/opt/php71-xdebug/xdebug.so"
xdebug.remote_host=127.0.0.1
xdebug.remote_connect_back=1    # Not safe for production servers
xdebug.remote_port=9000
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_autostart=true

可以在此处找到更多详细信息:https://bugs.xdebug.org/view.php?id=1354

PHP7.1 当前不受 xdebug 支持,(php 版本 <7.1)。您应该改用 7.0,并且不要忘记打开 xdebog.remote_enable