on-internet
← Community

Search a database table using any word from a multi-word search term with CodeIgniter's query builder [duplicate]

Stack Overflow ·

I am creating a CodeIgniter search for my bookshop project. It is okay with a single word search, but I am facing the problem when I search with multiple words. How I can fix this problem? MY controller public function search() { /*=== LOAD DYNAMIC CATAGORY ===*/ $this->load->model('admin_model'); $view['category'] = $this->admin_model->get_category(); /*==============================*/ $this->form_validation->set_rules('search_book', "Search",'required'); if($this->form_validation->run() == FALSE) { #...Redirected same page after action redirect($_SERVER['HTTP_REFERER']); } else { $query = $t

Comments

Sign in or sign up to comment and upvote.

No comments yet.