[Plugin: Navigable] Error when getting sub-navigation of a particular element:
-
Hi,
The plugin works great!
I’m getting an error when trying to get a sub-navigation of a particular element.
Here is my code:
<?php $nav = new NavigableWP('Main Navigation'); ?> <?php if ($sub_nav = $nav->find_branch(14)): ?> <ul> <?php foreach ($sub_nav as $elem): ?> <li class="nav-item<?php $elem->if_active('-current'); ?>"><a>url; ?>"><?php echo $elem->title; ?></a> <?php endforeach; ?> </ul> <?php endif; ?>
The error:
Fatal error: Call to undefined method NavigableWP::find_branch(…
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘[Plugin: Navigable] Error when getting sub-navigation of a particular element:’ is closed to new replies.