Welcome Guest, Not a member yet? Register   Sign In
Display dynamic menu and menu display rolewise login in Codeigniter
#6

(07-23-2018, 03:08 AM)jaydevvara Wrote:
(07-23-2018, 03:05 AM)Pertti Wrote:
(07-23-2018, 02:04 AM)jaydevvara Wrote: i did not understand

You asked how can you join these tables.

It's not really question of join, but I've shown you how you can get categories based on what user_reg table has.

It does not take account, for now, the parent categories, but it's a start.
yes got it but i did not fetch id in this condition

Code:
where_in('cid', $categories)

And here is my category table fetch  query so how implement  in this code


 public function listMenuLevel1() {

        $this->db->select("*");
       
        $this->db->where('parent_id=0');

        return $this->db->get('category')->result();
        return result;
    }

    public function listchildMenus($category_id) {

        $this->db->select("*");
        $this->db->where('parent_id', $category_id);
        return $this->db->get('category')->result();
   
        return result;
    }
Reply


Messages In This Thread
RE: Display dynamic menu and menu display rolewise login in Codeigniter - by jaydevvara - 07-23-2018, 03:10 AM



Theme © iAndrew 2016 - Forum software by © MyBB