thinphp mongodb

浏览:481 发布日期:2016/11/03 分类:求助交流 关键字: mongodb
public function Topic(){
header("Content-Type:text/html;charset=utf-8");
$id=$_GET['id'];
$rs=$this->mongo_topic->find($id);
$map['_id']=$rs['type_id']; //type_id存放的是category表中的_id
$re=$this->mongo_category->where($map)->find();
dump($rs);
dump($map);
dump($re);
$this->assign('category',$re);
$this->assign('topic',$rs);
$this->display();
}
为什么找不到数据$re返回null,map里面的值也是对的
最佳答案
评论( 相关
后面还有条评论,点击查看>>