search

Home  >  Q&A  >  body text

yii2 error connecting to mongodb3.2.4

Excuse me, what is going on? This is my first time using yii2, please give me some advice.
Mongodb3.2.4 installed locally, yii2 installed by composer.
The permissions of mongodb have been configured better,

Before using auth, the show dbs command cannot be used

After using auth verification, you can use the show dbs command to indicate that auth has been configured

yii2 configuration is as follows
composer.json

comp in web.php The configuration in onents

in the controller is as follows

and then an error is reported in the browser

Excuse me, what is going on? This is my first time using yii2, please give me some advice.

滿天的星座滿天的星座2789 days ago773

reply all(0)I'll reply

No reply
  • Cancelreply