Drivers Category

Drivers Update
Drivers

Install mongodb php driver

Version: 31.51.59
Date: 05 March 2016
Filesize: 0.131 MB
Operating system: Windows XP, Visa, Windows 7,8,10 (32 & 64 bits)

Download Now

< Previous Next> Description In this tutorial, we will discuss how to install PHP driver for Mongo DB on Linux, Windows and Mac. Install Mongo DB PHP driver on Linux You have to execute following command to install Mongo DB PHP driver on Linux : $ sudo pecl install mongo You must have internet connection enabled, pecl installed on PHP and must have root privilege to successfully run this command. If you want to compile the driver from source code, you have to do that manually. Advantage of doing this is, latest bug fixes will be included in your installation. You have to download Mongo DB PHP driver from Github. Go to the github website and search for mongo php driver. Download the package and then execute the following : $ tar zxvf mongodb-mongodb-php-driver-.tar.gz $ cd mongodb-mongodb-php-driver- $ phpize $./configure $ sudo make install After executing the previous commands, you have to make a change in your php.ini file. Open the file in your favorite text editor and extension_dir variable is pointing to the location of mongo.so. Also add 'extension=mongo.so' in file, save and restart your web server. Now if you point your browser to a php file containing 'echo phpinfo command, you can see that in the output, Mongo DB is shown as installed. Install Mongo DB PHP driver on Windows Pre compiled binaries are available on github. Download the version compatible to your PHP and Mongo DB version. Before you select to download a specific binary, remember the following : Opt for VC6 if you are running Apache web server. Opt for ' Thread safe' if you are running PHP as an Apache module, but if you are running PHP as CGI, go for ' non-thread safe'. Opt for VC9 if you are running IIS web server. After you download the binary suitable for you, unzip it and add 'php_mongo.dll' file to your PHP extension directory, which usually located as 'ext' folder.
If you're running IIS under Windows 7 and have PHP manager installed you'll also need to manually enable the extension. Start IIS Manager, select PHP Manager, under the section labeled PHP Extensions click on Enable or disable an extension, then enable the php_mongo.dll extension, and restart IIS.

© 2013-2016 gravexitwin.5v.pl