0
我想笨搜索,如果匹配然後我輸入數據顯示的結果,但不能匹配不能顯示數據..搜索,如果我的輸入數據是匹配或者不
這裏是我的模型:
public function get_search(){
$p_cat = $this->input->post('p_category');
$p_place = $this->input->post('p_place');
$p_price = $this->input->post('p_price');
$search = $this->input->post('search');
$this->db->like('p_category',$p_cat,$search);
$this->db->or_like('p_place',$p_place,$search);
$this->db->or_like('p_price',$p_price,$search);
$query = $this->db->get('tbl_property');
if($query->num_rows() > 0)
return $query->result_array();
else
return FALSE;
}
但這種模式的結果匹配或不匹配它顯示任何數據...
相同的結果...沒有解決 – Sabbir
你能解釋一下,你想要實現什麼? –