SproutCMS

This is the code documentation for the SproutCMS project

class Navigation

Provides navigation functions

Source code (50 results)

/modules/Demo/Controllers/DemoController.php   Highlighted file source

Line 20: use Sprout\Helpers\Navigation;
Line 54: Navigation::setPageNodeMatcher(new TreenodeRedirectMatcher('aaa'));
Line 69: Navigation::setPageNodeMatcher(new TreenodeRedirectMatcher('bbb'));

/modules/HomePage/Controllers/Admin/HomePageAdminController.php   Highlighted file source

Line 28: protected $navigation_name = 'Pages';
Line 51: * Proxies navigation to the 'page' controller.
Line 53: public function _getNavigation()
Line 56: return $pages->_getNavigation();

/skin/default/inner.php   Highlighted file source

Line 5: use Sprout\Helpers\Navigation;
Line 15: if (empty($browser_title)) $browser_title = Navigation::buildBrowserTitle($page_title);
Line 18: if (empty($banner)) $banner = Navigation::banner();
Line 64: <?php if (Navigation::matchedNode()): ?>
Line 65: <ul class="breadcrumb"><?php echo Navigation::breadcrumb('<li>', @$post_crumbs, '</li>'); ?></ul>

/skin/default/partials/_header.php   Highlighted file source

Line 3: use Sprout\Helpers\Navigation;
Line 83: <?php Navigation::simpleMenu(); ?>

/skin/default/wide.php   Highlighted file source

Line 5: use Sprout\Helpers\Navigation;
Line 14: if (empty($browser_title)) $browser_title = Navigation::buildBrowserTitle($page_title);
Line 17: if (empty($banner)) $banner = Navigation::banner();
Line 60: <?php if (Navigation::matchedNode()): ?>
Line 61: <ul class="breadcrumb"><?php echo Navigation::breadcrumb('<li>', @$post_crumbs, '</li>'); ?></ul>

/skin/harbor/inner.php   Highlighted file source

Line 5: use Sprout\Helpers\Navigation;
Line 10: if (empty($browser_title)) $browser_title = Navigation::buildBrowserTitle($page_title);

/sprout/Controllers/Admin/CategoryAdminController.php   Highlighted file source

Line 90: * Proxy for navigation => the main controller class
Line 92: public function _getNavigation()
Line 94: return $this->parent_inst->_getNavigation();

/sprout/Controllers/Admin/ContentSubscriptionAdminController.php   Highlighted file source

Line 53: public function _getNavigation() { return null; }

/sprout/Controllers/Admin/CronJobAdminController.php   Highlighted file source

Line 37: protected $navigation_name = 'Dev tools';
Line 66: * Returns the contents of the navigation pane for the list
Line 73: public function _getNavigation()
Line 75: $nav = new View('sprout/dbtools/navigation');

/sprout/Controllers/Admin/ExtraPageAdminController.php   Highlighted file source

Line 70: * Returns the contents of the navigation pane for the list
Line 72: public function _getNavigation()

/sprout/Controllers/Admin/HasCategoriesAdminController.php   Highlighted file source

Line 125: * Returns the contents of the navigation pane
Line 127: public function _getNavigation()
Line 190: $view = new View('sprout/admin/categories_navigation');

/sprout/Controllers/Admin/ListAdminController.php   Highlighted file source

Line 49: * Returns the contents of the navigation pane for the list
Line 51: public function _getNavigation()
Line 56: $view = new View('sprout/admin/list_navigation');
Line 74: * Returns the tools to show in the left navigation

/sprout/Controllers/Admin/ManagedAdminController.php   Highlighted file source

Line 69: * The friendly name used in the sidebar navigation. Defaults to matching the friendly name.
Line 71: protected $navigation_name;
Line 186: if ($this->navigation_name == '') $this->navigation_name = $this->friendly_name;
Line 261: * Returns the defined controller navigation name
Line 263: final public function getNavigationName() {
Line 264: return $this->navigation_name;
Line 1108: * Builds the HTML for showing the navigation through pages in the admin.
Line 1738: * Return the navigation for this controller
Line 1741: abstract public function _getNavigation();
Line 1751: * Returns tools to show in the left hand navigation. Return an empty array if no tools.

/sprout/Controllers/Admin/NoRecordsAdminController.php   Highlighted file source

Line 23: public function _getNavigation() { return ''; }

/sprout/Controllers/Admin/PageAdminController.php   Highlighted file source

Line 49: use Sprout\Helpers\Navigation;
Line 50: use Sprout\Helpers\NavigationGroups;
Line 147: Navigation::clearCache();
Line 152: * Returns the contents of the navigation pane for the tree
Line 154: public function _getNavigation()
Line 163: $view = new View('sprout/admin/page_navigation');
Line 169: $view->root = Navigation::getRootNode();
Line 440: Navigation::clearCache();
Line 1238: $root = Navigation::loadPageTree($_SESSION['admin']['active_subsite'], true);
Line 1245: $groups = NavigationGroups::getGroupsAdmin($top_parent['id']);
Line 1495: $root_node = Navigation::loadPageTree($_SESSION['admin']['active_subsite'], true);
Line 1778: Navigation::clearCache();
Line 1797: $view->root = Navigation::getRootNode();
Line 1814: $view->all_groups = NavigationGroups::getAllGroupsAdmin();
Line 1815: $view->all_extras = NavigationGroups::getAllExtrasAdmin();
Line 1843: $all_groups = NavigationGroups::getAllGroupsAdmin();
Line 1937: $root = Navigation::getRootNode();
Line 1976: Navigation::clearCache();
Line 2001: $root = Navigation::getRootNode();
Line 2225: Navigation::loadPageTree($_SESSION['admin']['active_subsite'], true);
Line 2227: $root = Navigation::getRootNode();
Line 2297: * Saves in the session data the currently open pages in the pages tree (navigation pane)
Line 2409: Navigation::clearCache();
Line 2448: Navigation::clearCache();
Line 2455: * Returns the tools to show in the left navigation
Line 2487: $items[] = "<li class=\"config\"><a href=\"page/clear_navigation_cache\">Clear navigation cache</a></li>";
Line 2732: public function clearNavigationCache()
Line 2736: Navigation::clearCache();

/sprout/Controllers/Admin/PerRecordPermissionAdminController.php   Highlighted file source

Line 86: * Return the navigation for this controller
Line 90: public function _getNavigation()

/sprout/Controllers/Admin/TreeAdminController.php   Highlighted file source

Line 56: * Returns the contents of the navigation pane for the tree
Line 58: public function _getNavigation()
Line 65: $view = new View('sprout/admin/tree_navigation');
Line 75: * Returns the tools to show in the left navigation
Line 497: * Saves in the session data the currently open items in navigation tree

/sprout/Controllers/Admin/WorkerJobAdminController.php   Highlighted file source

Line 40: protected $navigation_name = 'Dev tools';
Line 69: * Returns the contents of the navigation pane for the list
Line 76: public function _getNavigation()
Line 78: $nav = new View('sprout/dbtools/navigation');

/sprout/Controllers/AdminAjaxController.php   Highlighted file source

Line 31: use Sprout\Helpers\Navigation;
Line 368: Navigation::loadPageTree($_SESSION['admin']['active_subsite'], true);

/sprout/Controllers/AdminController.php   Highlighted file source

Line 44: use Sprout\Helpers\Navigation;
Line 116: Navigation::loadPageTree(@$_SESSION['admin']['active_subsite'], true);
Line 377: $this->setNavigation($view, $ctlr);
Line 408: $this->setNavigation($view, $ctlr);
Line 451: $this->setNavigation($view, $ctlr);
Line 484: $this->setNavigation($view, $ctlr);
Line 521: $this->setNavigation($view, $ctlr);
Line 556: $this->setNavigation($view, $ctlr);
Line 624: $this->setNavigation($view, $ctlr);
Line 730: $this->setNavigation($view, $ctlr);
Line 792: * @param ManagedAdminController $ctlr A controller to show the navigation of.
Line 805: $this->setNavigation($view, $ctlr);
Line 851: $this->setNavigation($view, $ctlr);
Line 1069: $this->setNavigation($view, $ctlr);
Line 1255: $this->setNavigation($view, $ctlr);
Line 1448: $this->setNavigation($view, $ctlr);
Line 1568: $this->setNavigation($view, $ctlr);
Line 1756: $this->setNavigation($view, new PageAdminController());
Line 1904: $this->setNavigation($view, $ctlr);
Line 1990: * Sets up the sidebar navigation for a view to show the navigation for a specific controller.
Line 1992: * @param View $view The view to set the navigation parameters for.
Line 1993: * @param Controller $ctlr The controller to use for navigation (and searching if supported).
Line 1995: private function setNavigation(View $view, Controller $ctlr)
Line 1997: // If no navigation has been set, use the default
Line 1999: $view->nav = $ctlr->_getNavigation();
Line 2003: $view->controller_navigation_name = $ctlr->getNavigationName();

/sprout/Controllers/AdvancedSearchController.php   Highlighted file source

Line 23: use Sprout\Helpers\Navigation;
Line 73: Navigation::setPageNodeMatcher(new TreenodeFrontendMatcher('advanced_search', 'form'));
Line 79: $page_node = Navigation::matchedNode();
Line 81: $page_title = $page_node->getNavigationName();

/sprout/Controllers/DbToolsController.php   Highlighted file source

Line 53: use Sprout\Helpers\Navigation;
Line 196: $nav = new View('sprout/dbtools/navigation');
Line 202: $view->controller_navigation_name = 'Dev tools';
Line 2461: $root = Navigation::loadPageTree($subsite_id, false, true);
Line 2485: Navigation::setPageNodeMatcher(new TreenodeValueMatcher('id', $fake_node['id']));

/sprout/Controllers/PageController.php   Highlighted file source

Line 28: use Sprout\Helpers\Navigation;
Line 56: private $navigation_node = null;
Line 75: $root = Navigation::getRootNode();
Line 79: $this->navigation_node = $node;
Line 131: $root = Navigation::getRootNode();
Line 133: $this->navigation_node = $node;
Line 214: if ($this->navigation_node) {
Line 215: $anc = $this->navigation_node->findAncestors();
Line 249: // Load navigation
Line 250: Navigation::setPageNodeMatcher(new TreenodeValueMatcher('id', $page['id']));
Line 251: if (! $this->navigation_node) {
Line 252: $this->navigation_node = Navigation::getRootNode()->findNodeValue('id', $page['id']);
Line 260: $page_view->browser_title = Navigation::buildBrowserTitle($page['name']);
Line 264: if ($this->navigation_node) {
Line 265: $anc = $this->navigation_node->findAncestors();
Line 266: $page_view->top_level_name = $anc[0]->getNavigationName();
Line 349: if (!empty($this->navigation_node)) {
Line 350: SocialMeta::setUrl($this->navigation_node->getFriendlyUrlNoPrefix());
Line 433: $root = Navigation::getRootNode();
Line 437: $name = $node->getNavigationName();

/sprout/Controllers/SearchController.php   Highlighted file source

Line 21: use Sprout\Helpers\Navigation;
Line 119: $page_view->browser_title = Navigation::buildBrowserTitle('Search');

/sprout/Helpers/ContentReplace.php   Highlighted file source

Line 75: $root = Navigation::getRootNode();

/sprout/Helpers/Fb.php   Highlighted file source

Line 1053: $options['root'] = Navigation::loadPageTree($options['subsite'], true, false);

/sprout/Helpers/LinkSpecPage.php   Highlighted file source

Line 28: $root = Navigation::getRootNode();

/sprout/Helpers/Navigation.php   Highlighted file source

Line 22: * Provides navigation functions
Line 24: class Navigation
Line 62: * @param bool $set_root Set the Navigation::$root_node paramater, as used by all the other methods.
Line 156: * Gets the root node of the currently loaded navigation tree
Line 165: * Alias for Navigation::getRootNode()
Line 174: * Nuke the navigation from the cache.
Line 255: echo "<a href=\"{$node->getFriendlyUrl()}\" class=\"main\">", Enc::html($node->getNavigationName()), "</a>";
Line 260: echo "<li class=\"on\"><a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";
Line 262: echo "<li><a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";
Line 337: echo "<li class=\"on\"><a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";
Line 339: echo "<li><a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";
Line 426: echo "<a href=\"{$node->getFriendlyUrl()}\" class=\"main\">", Enc::html($node->getNavigationName()), "</a>";
Line 431: echo "<li class=\"on\"><a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";
Line 433: echo "<li><a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";
Line 481: echo "<li class=\"on\"><a href=\"{$child->getFriendlyUrl()}\">", Enc::html($child->getNavigationName()), "</a>";
Line 483: echo "<li><a href=\"{$child->getFriendlyUrl()}\">", Enc::html($child->getNavigationName()), "</a>";
Line 496: * @param array $post_crumbs Additional crumbs to add after the navigation ones. Should be in the format url => label
Line 529: $crumbs[$node->getFriendlyUrl()] = $node->getNavigationName();
Line 640: echo "<li class=\"nav{$i} on\"><a href=\"{$page->getFriendlyUrl()}\">", Enc::html($page->getNavigationName()), "</a></li>";
Line 642: echo "<li class=\"nav{$i}\"><a href=\"{$page->getFriendlyUrl()}\">", Enc::html($page->getNavigationName()), "</a></li>";
Line 682: str_repeat('&nbsp;&nbsp;&nbsp;&nbsp;', $indent) . $page->getNavigationName(),
Line 724: return $ancestors[0]->getNavigationName();
Line 742: * Alias for {@see Navigation::matchedNode}()
Line 825: echo "<a href=\"{$node->getFriendlyUrl()}\">", Enc::html($node->getNavigationName()), "</a>";

/sprout/Helpers/NavigationGroups.php   Highlighted file source

Line 17: * Menu groups for front end main navigation
Line 19: class NavigationGroups
Line 201: $root = Navigation::getRootNode();

/sprout/Helpers/NavigationMenu.php   Highlighted file source

Line 25: class NavigationMenu
Line 29: * HTML to be returned prior to the first navigation item
Line 34: * HTML to be returned after the last navigation item
Line 40: * Note that if a sub-class overrides the {@see navigation::sub_menu} method
Line 43: protected static $dropdown_view_name = 'sprout/navigation_dropdown';
Line 56: $root = Navigation::getRootNode();
Line 59: $selected_node = Navigation::getMatchedNode();
Line 85: // Fetch the various navigation groups before the rendering, so it can be determined if there
Line 88: $group_names = NavigationGroups::getAllNames($node['id']);
Line 90: $group_id = NavigationGroups::getId($node['id'], $position);
Line 101: $out .= '<a href="' . Enc::html($node->getFriendlyUrl()) . '">' . Enc::html($node->getNavigationName()) . '</a>';
Line 147: * Determine the classes for the LI for a navigation item
Line 189: $view->extra = NavigationGroups::getExtras($parent_node['id']);

/sprout/Helpers/Page.php   Highlighted file source

Line 34: $root = Navigation::getRootNode();
Line 57: $root = Navigation::getRootNode();
Line 73: * @throws Exception if there's no matching tool page in the {@see Navigation} tree
Line 79: $node = Navigation::getRootNode()->findNode($matcher);
Line 93: $node = Navigation::getMatchedNode();
Line 330: * Navigation::matchedNode()
Line 343: $node = Navigation::matchedNode();
Line 391: $root_node = Navigation::getRootNode();
Line 433: $list[] = ['href' => $node->getFriendlyUrl(), 'text' => $node->getNavigationName()];

/sprout/Helpers/Pagenode.php   Highlighted file source

Line 32: throw new Exception("Method not supported for page trees, use Navigation::loadPageTree instead.");
Line 72: * Returns the name that should be used to represent this node when rendering navigation elements
Line 76: public function getNavigationName()

/sprout/Helpers/PageRouting.php   Highlighted file source

Line 89: $root = Navigation::getRootNode();

/sprout/Helpers/RteLibraryPages.php   Highlighted file source

Line 45: $root = Navigation::loadPageTree($_SESSION['admin']['active_subsite'], true);

/sprout/Helpers/SitemapGenPages.php   Highlighted file source

Line 16: use Sprout\Helpers\Navigation;
Line 30: $root = Navigation::getRootNode();

/sprout/Helpers/Sprout.php   Highlighted file source

Line 620: $root = Navigation::getRootNode();

/sprout/Helpers/SproutVariable.php   Highlighted file source

Line 39: public $navigation;
Line 56: $this->navigation = new Navigation();

/sprout/tests/navigationTest.php   Highlighted file source

Line 14: use Sprout\Helpers\Navigation;
Line 18: class navigationTest extends PHPUnit_Framework_TestCase
Line 89: $root = Navigation::loadPageTree(1, true, false);
Line 102: $root = Navigation::loadPageTree(1, false, false);
Line 134: $actual = Navigation::customBreadcrumb($crumbs);

/sprout/views/admin/main_layout.php   Highlighted file source

Line 205: <div class="navigation-area">
Line 209: <div id="navigation" class="mainbar">
Line 284: <!-- Navigation -->
Line 286: <h2 class="icon-before icon-insert_drive_file"><?php echo Enc::html($controller_navigation_name); ?></h2>

/sprout/views/admin/page_add.php   Highlighted file source

Line 19: use Sprout\Helpers\NavigationGroups;
Line 37: Form::nextFieldDetails('Name', true, 'This name will appear as the primary heading of this page, and will also be used in your navigation and sitemap');
Line 42: Form::nextFieldDetails('Parent page', false, 'The location in your navigation where this page will be displayed');
Line 56: Form::nextFieldDetails('Menu group', false, 'The group to place this page into in the main navigation menu');
Line 57: echo Form::dropdown('menu_group', ['-dropdown-top' => 'None -- Top level page', '-wrapper-class' => 'white'], NavigationGroups::getAllNamesAdmin());

/sprout/views/admin/page_edit.php   Highlighted file source

Line 22: use Sprout\Helpers\Navigation;
Line 23: use Sprout\Helpers\NavigationGroups;
Line 54: $root = Navigation::getRootNode();
Line 90: echo Form::dropdown('menu_group', ['-dropdown-top' => 'None -- Don\'t show in menu'], NavigationGroups::getAllNamesAdmin());
Line 148: Form::nextFieldDetails('Web-browser title (defaults to: ' . Navigation::buildBrowserTitle($page['name']) . ')',
Line 159: Form::nextFieldDetails('Alternate navigation title', false, 'Override the default title that appears in links and navigation breadcrumbs for this page.');

/sprout/views/children_page_gallery.php   Highlighted file source

Line 23: <p class="children-gallery-list-item-title"><?php echo Enc::html($page->getNavigationName()); ?></p>

/sprout/views/navigation_dropdown.php   Highlighted file source

Line 4: use Sprout\Helpers\NavigationMenu;
Line 12: <h2 class="mega-menu-preview-title"><?php echo Enc::html($parent_node->getNavigationName()); ?></h2>
Line 42: $classes = NavigationMenu::determineClasses($node, 2, null, $selected_node, $selected_ancestors, false);
Line 45: echo '<a href="', Enc::html($node->getFriendlyUrl()), '">', Enc::html($node->getNavigationName()), '</a>';

/sprout/Widgets/ChildrenGalleryWidget.php   Highlighted file source

Line 17: use Sprout\Helpers\Navigation;
Line 48: $root_node = Navigation::getRootNode();
Line 53: $matcher = Navigation::getPageNodeMatcher();
Line 119: $root = Navigation::loadPageTree($row['id'], true, false);

/sprout/Widgets/ChildrenPagesWidget.php   Highlighted file source

Line 17: use Sprout\Helpers\Navigation;
Line 39: $root_node = Navigation::getRootNode();
Line 42: $matcher = Navigation::getPageNodeMatcher();
Line 58: $page_title = Enc::html($page->getNavigationName());

/sprout/Widgets/RelatedLinksWidget.php   Highlighted file source

Line 19: use Sprout\Helpers\Navigation;
Line 40: $root_node = Navigation::getRootNode();
Line 43: $matcher = Navigation::getPageNodeMatcher();
Line 60: $out = str_replace('SECTION', Enc::html($top_anc->getNavigationName()), $out);
Line 70: $page_title = Enc::html($top_anc->getNavigationName());
Line 107: $node_title = Enc::html($node->getNavigationName());

/sprout/Widgets/SitemapWidget.php   Highlighted file source

Line 17: use Sprout\Helpers\Navigation;
Line 37: $root_node = Navigation::getRootNode();
Line 65: $node_title = Enc::html($node->getNavigationName());

A total of 254 lines in 50 files were found