Navigation Tags
navigation
Coupled to a helper function, displays one level of one menu navigation.
Used helper : get_navigation()
<!-- Sample code --> <ion:navigation level="0" active_class="active" menu="my_menu" tag="ul" id="my_nav" class="nav" /> <!-- Example of result --> <ul id="my_nav" class="nav"> <li class="active"><a class="active" href="http://my_domain.tld/home/">Home</a></li> <li><a href="http://my_domain.tld/service/">Our Services</a></li> <li><a href="http://my_domain.tld/about/">About our company</a></li> </ul>
| Attribute | Optional | Values |
|---|---|---|
| level | no | The wished displayed level. Start at 0. |
| menu | yes | The wished displayed menu. Default value : main |
| tag | yes | Puts the results into the given tag |
| id | yes | Adds the HTML id attribute to the produced tag. |
| class | yes | Adds the HTML class attribute to the produced tag. |
| helper | yes | <Name of the helper>:<function> to use to display the navigation menu. This is another way to implement your own helper to display the navigation. If your helper file is called my_navigation_menu.php and your helper function is named my_navigation_func(), you will write : <ion:languages helper="my_navigation_menu:my_navigation_func" /> |
tree_navigation
A tree based navigation menu, as a unordered HTML list (<ul>...</ul>).
Coupled to the helper : get_tree_navigation()
<!-- Sample code -->
<ion:tree_navigation level="0" depth="2" active_class="active" menu="my_menu" tag="ul" id="my_nav" class="nav" />
<!-- Example of result -->
<ul id="my_nav" class="nav">
<li><a href="home">Home</a></li>
<li class="active"><a href="services">Our Services</a></li>
<ul>
<li class="active"><a class="active" href="webdesign">Webdesign</a></li>
<li><a href="coding">Coding</a></li>
</ul>
<li><a href="about">About us</a></li>
</ul>
| Attribute | Optional | Values |
|---|---|---|
| level | no | The wished displayed level. Start at 0. |
| depth | no | Depth you want your menu to go. "2" means 2 levels, including the starting level. |
| menu | yes | The wished displayed menu. Default value : main |
| tag | yes | Puts the results into the given tag |
| id | yes | Adds the HTML id attributes to the produced tag. |
| class | yes | Adds the HTML class attributes to the produced tag. |
| helper | yes | <Name of the helper>:<function> to use to display the navigation menu. This is another way to implement your own helper to display the navigation. If your helper file is called my_navigation_menu.php and your helper function is named my_navigation_func(), you will write : <ion:languages helper="my_navigation_menu:my_navigation_func" /> |
Customize the navigation menu
Navigation tags are coupled to helpers functions, located in : /application/helpers/navigation_helper.php
If you wish to create your own helper to display the menu in a different way, just copy this file to : /themes/your_theme/helpers/ and modify it.
The tag will automatically take your helper instead the default one.
To customize the <ion:navigation /> tag : Modify the function : get_navigation()
To customize the <ion:tree_navigation /> tag : Modify the function : get_tree_navigation()
breadcrumb
Used to display the current page location in the navigation tree, example "home>blog"
| Attribute | Optional | Values |
|---|---|---|
| class | yes | |
| id | yes | |
| full_tag | ||
| lang_url | ||
| separator |
Example :
<!-- Breadcrumb --> <ion:translation term="you_are_here" /> : <ion:breadcrumb lang_url="true" />