如何使用PHP 5.5.14在Yosemite上启用fastcgi

al_*_*x13 4 php cgi fastcgi phpstorm

我在Mac OSX Yosemite 10.10上使用PHPStorm 9,当我尝试在浏览器中打开项目时,它返回"502 Bad Gateway"错误.

在PHPStorm中,它说php-cgi没有找到

Please ensure that configured PHP interpreter built as CGI program (--enable-fastcgi was specified)
Run Code Online (Sandbox Code Playgroud)

我在这个问题中遵循了GotchaRob的回答,但它没有帮助.不幸的是我还不能发表评论,所以我创建了一个新问题.

如果有人能提供一些帮助,我将非常感激.谢谢.

小智 5

我用这个解决方案解决了这个问题

http://barratmp.blogspot.ru/2014/10/the-core-yosemite-php-version-is-5.html

但我只安装php5.6

brew install homebrew/php/php56
Run Code Online (Sandbox Code Playgroud)

安装后指向phpstorm中的php6.5