var db = req.db;
var collection = db.collection('abc');
collection.find({}).toArray(function(err,data){
res.render('index',{
'art_list' : data
});
})
现在用的是这个方法
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
这个问题非常基础啊。。。你是学node.js入门web开发的么。。。