I have read few post here on solving my issue but neither works for php-5.6.
I downloaded php_mongo-1.6.8.zip and php_mongo-1.6.7.zip and tried all the .dll extensions and all of them gives one or the other error.
Error message:
PHP Startup: Unable to load dynamic library 'C:\xampp\php\ext\php_mongo-1.6.8-5.6-vc11-x86_64.dll' - %1 is not a valid Win32 application.
in Unknown on line 0
PHP Startup: Unable to load dynamic library 'C:\xampp\php\ext\php_mongo-1.6.8-5.6-vc11.dll' - The specified module could not be found.
in Unknown on line 0
P.S.: I am using XAMPP for my environment.
I installed mongo extension with following steps:
C:\xampp
on Windows 7php_mongo.dll
and copy it toC:\xampp\php\ext
C:\xampp\php\php.ini
lineextension=php_mongo.dll
Without further configuration, I see mongo extension in command line (
C:\xampp\php\php.exe -i | findstr mongo
) but Apache complains about missinglibsasl.dll
and mongo is missing in http://localhost/dashboard/phpinfo.php. Ok, what next?C:\xampp\php\libsasl.dll
toC:\xampp\apache\bin\
, restart Apache and enjoy.This howto worked for me well. I hope it will help to resolve your issue.
In your php.ini file, uncomment this configuration, and restart your Apache Server:
If it doesn't work, try to put an absolute path to your extension directory, where
php_mongo-1.6.8-5.6-vc11.dll
reside.UPDATE
I have found this information in PHP_OFFICIAL_WEBSITE
I think you should also add
libsasl.dll
to your PATH environment variableFollow below steps to make Mongo work for PHP-5.6
extension=php_mongo.dll
Note : Check the "mongo" module is loaded or mot using phpinfo()
Follow the steps described here:
http://devzone.co.in/configure-mongodb-php-windows-xampp-5-simple-steps/
User "kba" described the same steps. This steps should work. Just do everything that's indicated there.