From 64fbc3d08c1dbf7db07149c6b63f0addcacfb8a2 Mon Sep 17 00:00:00 2001 From: Steve Sutton Date: Thu, 4 Sep 2014 12:25:31 -0400 Subject: [PATCH] Update Mobile navigation Add class current to the currently selected page link. --- Toolkit/Page.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Toolkit/Page.php b/Toolkit/Page.php index 4478769..86a9ced 100755 --- a/Toolkit/Page.php +++ b/Toolkit/Page.php @@ -418,7 +418,7 @@ class Toolkit_Page } $this->pageTitle = $this->_getPageTitle($this->_catid); $this->pageTitleShort = $this->_getPageTitleShort($this->_catid); - + $bodyFactory = new Toolkit_Template_Page_BodyFactory( $this->_breadCrumbs, $this->_pageGateway, @@ -685,6 +685,9 @@ class Toolkit_Page $classes[] = $node['class']; } } + if ($this->_catid == $node['id']) { + $class = ' class="current"'; + } if (!empty($node['pages'])) { $classes[] = 'has-dropdown'; @@ -753,7 +756,7 @@ class Toolkit_Page return $title; } - + /** * Returns page title * -- 2.17.1