我在 macOS Catalina 10.15.3 系统上本地安装了 PHP;
php -i
phpinfo()
PHP Version => 7.3.11
我已经启动并运行 Nginx 来提供静态文件:
让 Nginx 和 PHP 提供脚本文件的最简单方法是什么?我知道那里有很多文章,但所有文章都以不同的方式存在,并非所有文章都适合我的需要。我看过了https://www.php.net/manual/en/install.fpm.install.php但找不到php.ini
我正在使用的网络服务器?由于我还不能提供 PHP 文件,所以我不能简单地将文件放在根目录上并使用:phpinfo()
php -i | grep "Configuration File"
Configuration File (php.ini) Path => /etc
Loaded Configuration File => (none)
有关本地设置的更多信息;
server {
listen 8080;
server_name localhost;
#charset koi8-r;
access_log logs/host.access.log main;
location / {
root html;
index index.html index.htm index.php;
}
因此,尝试安装PHP-FPM
并立即开始乐趣和游戏(在线参考);
$ brew tap homebrew/dupes
$ brew tap homebrew/php
$ brew install --without-apache --with-fpm php71
Error: homebrew/dupes was deprecated. This tap is now empty as all its formulae were migrated.
Error: homebrew/php was deprecated. This tap is now empty as all its formulae were migrated.
Error: invalid option: --without-apache
如果您能提供一些线索或推动我朝正确的方向前进,那就太好了。