php – Symfony2:文件管理器问题与mongodb

前端之家收集整理的这篇文章主要介绍了php – Symfony2:文件管理器问题与mongodb前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
在composer.json安装symfony2和 mongodb之后(安装成功完成).但是,当我执行应用程序时,我收到以下错误消息:
InvalidArgumentException: Unable to replace alias "doctrine_mongodb.odm.document_manager" with "doctrine.odm.mongodb.document_manager".

这是我的composer.json:

"require": {
    "PHP": ">=5.3.3","symfony/symfony": "2.2.*","doctrine/orm": "~2.2,>=2.2.3","doctrine/doctrine-bundle": "1.2.*","twig/extensions": "1.0.*","symfony/assetic-bundle": "2.1.*","symfony/swiftmailer-bundle": "2.2.*","symfony/monolog-bundle": "2.2.*","sensio/distribution-bundle": "2.2.*","sensio/framework-extra-bundle": "2.2.*","sensio/generator-bundle": "2.2.*","jms/security-extra-bundle": "1.4.*","jms/di-extra-bundle": "1.3.*","doctrine/mongodb-odm-bundle": "3.0.*"
},

有没有人有想法?

您必须将doctrine_mongodb配置添加到app / config / config.yml中
doctrine_mongodb:
connections:
    default:
        server: mongodb://localhost:27017
        options: {}
default_database: kickass
document_managers:
    default:
        auto_mapping: true
原文链接:https://www.f2er.com/php/132464.html

猜你在找的PHP相关文章