unifyyeteng 发表于 2012-12-26 19:25:30

ci 中where

1. $this->db->where('entry_id', $this->uri->segment(3));

2. $data['query']=$this->db->get('comment');

这里第一句是不是没有执行查询, 而是把entry_id=$this->uri->segment(3)暂时存在那

轮到执行$this->db->get('comment');时才把where条件自动加进去
页: [1]
查看完整版本: ci 中where