MongoDb not found in ZF2 controller


I have few controllers in my zf2 project which work perfectly in the browser using apache and via command line.

However, I recently installed MongoDb so I can store some data using the driver found in (

My issue is, when I try to access the driver via controller + browser, I get the following message error in my apache logs :

PHP Fatal error: Class 'MongoDb\Driver\Manager' not found. 'MongoDb\Driver\Manager' is the namespace for this Driver.

If I execute some other controllers via command line, MongoDb works correctly.

Does anyone know why is this happening? I cannot see the issue :(

Thank you

Show source
| php   | zend-framework   | zend-framework2   | mongodb   2017-09-23 11:09 1 Answers

Answers to MongoDb not found in ZF2 controller ( 1 )

  1. 2017-09-23 13:09

    I found that my php.ini was pointing to instead of

    That fixed the issue

    Thank you for your help

Leave a reply to - MongoDb not found in ZF2 controller

◀ Go back