two db conecctions...
I want to keep using this class but i dont want open two db sessions (with the password in two different files)... I want to use my own $db conection class, not to create a new conn (or need to change the entire script).... I think that must be optional....
ops! i did not solved it yet...
It shouldn't be all that bad to implement. Pass in a config param called connection containing the Mongo class. Check if $config['connection'] exists, and if so don't require them to specify a database. Next, do a verification on $config['connection'] to ensure it's of class Mongo. Later in _init(), don't perform $this->_connection = if you've already set $this->_connection and it's an instance of Mongo via !empty($this->_connection) && get_class($this->_connection) == 'Mongo'.