I have the following find (from mongodb) field working well but when I try to use the preg_replace, I get the following error message
Notice: array to string conversion in ...
My code:
$mongorow = $collection->findOne(array('_id' => new MongoId($id))); //finds based on ID
$dotodot = preg_replace("/_DOT_/", ".", $mongorow);
$dotodot = preg_replace("/_DOT_/", ".", implode('', $mongorow));