How to set tree view in dynamic menu in codeigniter - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: General (https://forum.codeigniter.com/forumdisplay.php?fid=1) +--- Forum: Regional User Groups (https://forum.codeigniter.com/forumdisplay.php?fid=25) +--- Thread: How to set tree view in dynamic menu in codeigniter (/showthread.php?tid=71354) |
How to set tree view in dynamic menu in codeigniter - jaydevvara - 08-03-2018 Hello guyyz i need help in design,i don't have ideas about design, i have created dynamic menu in codeigniter i want to set that menu in treeview. First click on parent menu after open child menus, so how to implement it help me Here is My View Code: <?php foreach ($test as $val) { $array = explode(",", $val->category_id); } foreach ($get_cat as $key => $value) { if (in_array($value->category_id, $array)) { echo $value->category_name . ' '; //Here my menu print } } ?> RE: How to set tree view in dynamic menu in codeigniter - InsiteFX - 08-07-2018 Do you mean set the active state or some thing else? RE: How to set tree view in dynamic menu in codeigniter - jaydevvara - 08-10-2018 (08-07-2018, 09:00 AM)InsiteFX Wrote: Do you mean set the active state or some thing else? yes active state and parent menu,child menu RE: How to set tree view in dynamic menu in codeigniter - InsiteFX - 08-11-2018 You can try this, I created it a while back so hope it still works. No time to test right now. PHP Code: /** Hope it helps. |