Navigation for a complete Noob?
Hi,
I'm absolutely brand new to Fuel CMS and I've been trying to work my way through the documentation, but I'm struggling to understand the process of creating navigation elements.
I think that to create a navigation bar, you need to define your pages in the _variables/nav.php file as part of the $nav array. And, indeed, when I do this, I can render this array in my header block using echo fuel_nav(array('render-type'=>'breadcrumb','container_tag_id' => 'topmenu', 'item_id_prefix' => 'topmenu_'));
However, what do I do if I need to have a top menu and a separate side menu that contain different items? If the fuel_nav function automatically renders the content of the $nav variable, is it possible to have multiple nav variables to contain different navigation bars?
Comments
echo fuel_nav(array('render-type'=>'breadcrumb','container_tag_id' => 'topmenu', 'item_id_prefix' => 'topmenu_', 'parent' => uri_segment(1)));
Alternatively, you create a totally different navigation structure in the nav.php file using a different variable other then $nav and you can specify the "var" parameter in fuel_nav like so:
echo fuel_nav(array('render-type'=>'breadcrumb','container_tag_id' => 'topmenu', 'item_id_prefix' => 'topmenu_', 'var' => 'other_nav'));