Skip to content
PHP Python C M4 Shell C++ Other
Branch: master
Clone or download
alcaeus Merge pull request #1024 from alcaeus/phpc-991
PHPC-991: Handle duplicates in URI options array
Latest commit 987fa38 Sep 30, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
.appveyor PHPC-1114: Add template.rc file to embed the right MongoDB version in… Feb 27, 2018
.evergreen PHPC-1415: Disable retryWrites for non-RS sharded cluster on Evergreen Aug 21, 2019
.github/ISSUE_TEMPLATE Update Jul 16, 2019
.travis.scripts PHPC-1415: Disable retryWrites for sharded cluster without replica set Jul 23, 2019
bin Add @alcaeus to package.xml template Aug 21, 2019
scripts PHPC-1290: Update sharded test clusters to have multiple mongoses Aug 28, 2019
src PHPC-1428: Bump libmongoc to 1.15.1 Sep 2, 2019
tests PHPC-991: Handle duplicates in URI options array Sep 30, 2019
.appveyor.yml PHPC-1390: Add PHP 7.3 on AppVeyor Aug 5, 2019
.clang-format PHPC-1118: Add detection of the correct clang-format binary Feb 23, 2018
.gitignore Add preliminary Evergreen Config Feb 14, 2019
.gitmodules PHPC-1174: Bump libbson and libmongoc to 1.10.0-dev May 18, 2018 Add travis and coveralls support Jun 20, 2014
.travis.yml Improve docs for bumping libmongoc/libbson Sep 11, 2019
CREDITS PHPC-1114: Add template.rc file to embed the right MongoDB version in… Feb 27, 2018
LICENSE Add Apache 2 license Dec 19, 2014
Makefile.frag PHPC-1364: Upgrade libmongoc to 1.14.0 May 1, 2019 Revise embed code for Coveralls badge May 30, 2019
Vagrantfile Add 4.0 to Vagrant test set-up Jun 19, 2018
config.m4 PHPC-1369: Upgrade libmongoc to 1.15.0 Aug 20, 2019
config.w32 PHPC-1369: Update libmongoc to latest 1.15-dev Aug 12, 2019
phongo_compat.c PHPC-1166: Remove inline hint to fix linking issues on Windows May 18, 2018
phongo_compat.h PHPC-1122: Remove unnecessary SUPPRESS_UNUSED_WARNING macro Oct 2, 2018
phongo_version.h Master branch is now 1.7-dev Sep 4, 2019
php_bson.h PHPC-1270: Upgrade libmongoc to 1.13.0 Sep 20, 2018
php_phongo.c PHPC-991: Override safe and slaveok options correctly Sep 30, 2019
php_phongo.h PHPC-1290: Adapt server selection logic to respect session pinning Aug 28, 2019
php_phongo_classes.h PHPC-1123: Create interface for Cursor class Oct 9, 2018
php_phongo_structs.h PHPC-1301: Use bool for php_phongo_cursor_t.got_iterator Feb 28, 2019
template.rc PHPC-1114: Add template.rc file to embed the right MongoDB version in… Feb 27, 2018

MongoDB PHP Driver

Travis Build Status AppVeyor Build Status Coverage Status

This extension is developed atop the libmongoc and libbson libraries. It provides a minimal API for core driver functionality: commands, queries, writes, connection management, and BSON serialization.

Userland PHP libraries that depend on this extension may provide higher level APIs, such as query builders, individual command helper methods, and GridFS. Application developers should consider using this extension in conjunction with the MongoDB PHP library, which implements the same higher level APIs found in MongoDB drivers for other languages (as well as the legacy PHP driver).



To build and install the driver:

$ pecl install mongodb
$ echo "" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`

Additional installation instructions may be found in the documentation.

This extension is intended to be used alongside the MongoDB PHP Library, which is distributed as the mongodb/mongodb package for for Composer.

Reporting Issues

Issues pertaining to the extension should be reported in the PHPC project in MongoDB's JIRA. Library-related issues should be reported in the PHPLIB project.

For general questions and support requests, please use one of MongoDB's Technical Support channels.

Security Vulnerabilities

If you've identified a security vulnerability in a driver or any other MongoDB project, please report it according to the instructions in Create a Vulnerability Report.


Development is tracked in the PHPC project in MongoDB's JIRA. Documentation for contributing to this project may be found in

You can’t perform that action at this time.