【发布时间】:2014-02-28 18:55:27
【问题描述】:
我花了 2 天时间尝试在带有 MAMP (2.2) 的 Mac 10.8 上安装 mongo php 驱动程序,但这几乎是不可能的...... 我试过了: Installing Mongo Driver on MAMP 和这个 Mongo PHP Driver 1.2.10 with MAMP
我在 MAMP 上选择了 5.4.19 php 版本。
我已经安装了mongo驱动:
sudo pecl install mongo
我没有错误,但是一旦我重新启动 MAMP,我在加载过程中遇到了这个错误:
PHP Warning: PHP Startup: mongo: Unable to initialize module
Module compiled with module API=20090626
PHP compiled with module API=20121212
These options need to match
in Unknown on line 0
phpize 的输出是:
Configuring for:
PHP Api Version: 20090626
Zend Module Api No: 20090626
Zend Extension Api No: 220090626
php -v 的输出为:
PHP 5.5.3 (cli) (built: Sep 18 2013 14:31:13) ...
所以版本与 MAMP 不匹配。 我尝试在 MAMP 上选择相同的版本,但我遇到了同样的问题...
有什么提示吗?
非常感谢!
【问题讨论】:
标签: php macos mongodb mamp mamp-pro