douyan1244 2019-06-25 23:06
浏览 110

CLI与内置服务器中包含奇怪的PHP .ini

My current config: - MacOS Mojave - PHP 7.3.5 installed via Homebrew - XDebug 2.7.2 installed via PECL - get_loaded_extensions() in both CLI and built-in server is enabled

While trying to configure XDebug on Mac I came across a strange problem. When calling

$ php --ini

I get

Configuration File (php.ini) Path: /usr/local/etc/php/7.3
Loaded Configuration File:         /usr/local/etc/php/7.3/php.ini
Scan for additional .ini files in: /usr/local/etc/php/7.3/conf.d
Additional .ini files parsed:      /usr/local/etc/php/7.3/conf.d/ext-opcache.ini,
/usr/local/etc/php/7.3/conf.d/ext-xdebug.ini

whereas calling

print php_ini_scanned_files();

in the script executed via built-in PHP server yields

/usr/local/etc/php/7.3/conf.d/ext-opcache.ini

Web server does not include my xdebug config, therefore there is no way to set xdebug.remote_enable=1 option properly.

What is even "better" is that editing /usr/local/etc/php/7.3/php.ini to cause parsing errors gives no warnings whatsoever.

I'm puzzled. Does anyone has any idea what's the reason behind this?

  • 写回答

0条回答

    报告相同问题?

    悬赏问题

    • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
    • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
    • ¥20 有关区间dp的问题求解
    • ¥15 多电路系统共用电源的串扰问题
    • ¥15 slam rangenet++配置
    • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
    • ¥15 ubuntu子系统密码忘记
    • ¥15 信号傅里叶变换在matlab上遇到的小问题请求帮助
    • ¥15 保护模式-系统加载-段寄存器
    • ¥15 电脑桌面设定一个区域禁止鼠标操作