Home  >  Article  >  Backend Development  >  How to install mongodb extension in php7

How to install mongodb extension in php7

藏色散人
藏色散人Original
2021-05-11 10:18:531867browse

How to install mongodb extension in php7: first download "mongodb-1.6.0.tgz"; then enter "mongodb-1.6.0"; finally modify php.ini and restart.

How to install mongodb extension in php7

The operating environment of this article: linux5.9.8 system, PHP7.0&&mongodb1.6.0 version, DELL G3 computer

PHP7 Install MONGODB extension

Download mongodb-1.6.0.tgz wget https://pecl.php.net/get/mongodb-1.6.0.tgz If the version is too low, some syntax is different, at least 1.5 or above

Enter mongodb-1.6.0

/www/server/php/70/bin/phpize && ./configure --with-php-config=/www/server/php/70/bin/php-config
make && make install

Modify php.ini

Restart

Done!

Recommended learning: "PHP Video Tutorial"

The above is the detailed content of How to install mongodb extension in php7. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn