You are not logged in.
Pages: 1
I have found a lot of things using the last post I made.
But I have a new question.
Well I fixed the menu, with this code
<?
$cms = $cms->getNavByParent(0,5);
foreach($cms as $item) {
print '<li ><a href="'.$item['link'].'">'.$item['title'].'</a></li>';
if (!empty($item['children'])) {
// foreach ($item['children'] as $submenu) {
// print '<ul><li ><a href="'.$submenu['link'].'">'.$submenu['title'].'</a></li>';
// }
}
?>
But I want to load a specific menu, for example
Home
-Contact
--MAKE TICKET
-FAQ
--HOW LOGIN
--HOW TO UPLOAD something (whatever)
I have a header menu
With
[HOME | CONTACT | FAQ ]
But on the FAQ page I want to load the FAQ menu , without thousand foreach loops, is there an more simple solution
Daan
--
Offline
To get two levels down from the top level navigation item (e.g. return all of FAQs descendants when on FAQ, HOW TO LOGIN, or HOW TO UPLOAD):
$toplevel = $cms->getTopLevelNavigationId();
$nav = $cms->getNavByParent($toplevel, 2);
To get just the children of the current page:
$nav = $cms->getNavByParent($bigtree["page"]["id"], 1);
Offline
Pages: 1