MAC OS中brew安裝的PHP使用brew安裝拓展
PHP拓展(可裝可不裝,brew拓展方便)
MongoDb拓展(前面安裝的是數據庫)
安裝前先search
brew search mongo
PHP56 安裝 MongoDb拓展
sphp 56
brew install php56-mongo
PHP71 安裝 MongoDb拓展
sphp 71
brew install php71-mongodb
重啓
sudo apachectl -k restart
,然後http://localhost
查看拓展開啓沒有
PHP各個版本安裝xdebug拓展
PHP56 安裝 xdebug拓展
sphp 56
brew install php56-xdebug
PHP71 安裝 xdebug拓展
sphp 71
brew install php71-xdebug
重啓
sudo apachectl -k restart
,然後http://localhost
查看拓展開啓沒有
PHP安裝YAML,symfony框架使用速度提高x5
PHP56 安裝 YAML拓展
sphp 56
brew install php56-yaml
PHP71 安裝 YAML拓展
sphp 71
brew install php71-yaml
安裝 OPcache and APCu(緩存機制,加快PHP的編譯速度)
在PHP56裏面安裝
$ sphp 56
$ brew install php56-opcache
$ brew install php56-apcu
在PHP71裏面安裝
$ sphp 71
$ brew install php71-opcache
$ brew install php71-apcu
重啓
sudo apachectl -k restart
,然後http://localhost
查看拓展開啓沒有