From: Steve Sutton Date: Thu, 10 Jul 2014 16:17:32 +0000 (-0400) Subject: setup navigation X-Git-Tag: v1.0^2~35 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=c15684b24b7781e15ddf5b07677200a8b39dd301;p=web%2FBigFore.git setup navigation create array for defining the top level pages used in the navigation. --- diff --git a/Toolkit/Page.php b/Toolkit/Page.php index b0ce188..97853a7 100755 --- a/Toolkit/Page.php +++ b/Toolkit/Page.php @@ -568,7 +568,6 @@ class Toolkit_Page $this->_pageGateway ); $nav = $sideNav->getNavigation(); - unset($nav[0]); $html = $this->_arrayToListHTML($nav); return ($html) ? $html : ''; } diff --git a/Toolkit/Template/Navigation/AllInOneSideNav.php b/Toolkit/Template/Navigation/AllInOneSideNav.php index 2f2df53..93204aa 100755 --- a/Toolkit/Template/Navigation/AllInOneSideNav.php +++ b/Toolkit/Template/Navigation/AllInOneSideNav.php @@ -56,12 +56,12 @@ class Toolkit_Template_Navigation_AllInOneSideNav try { $navArray = array(); $dbh = Toolkit_Database::getInstance(); - $pages = (defined('ALL_IN_ONE_INCLUDED') - && ALL_IN_ONE_INCLUDED) - ? unserialize(ALL_IN_ONE_INCLUDED) + $topLevelPages = (defined('TOP_LEVEL_PAGES') + && TOP_LEVEL_PAGES) + ? unserialize(TOP_LEVEL_PAGES) : null; - $includedPages = (!empty($pages)) - ? "AND (parent != 0 OR id IN (".implode(',', $pages)."))" + $includedPages = (!empty($topLevelPages)) + ? "AND (parent != 0 OR id IN (".implode(',', $topLevelPages)."))" : ''; $memberPages = (defined('MEMBERS_DB') && MEMBERS_DB) ? "AND id NOT IN (".MEMBERS_CATEGORY.")" diff --git a/setup.phtml b/setup.phtml index a07a99c..7d80027 100644 --- a/setup.phtml +++ b/setup.phtml @@ -54,8 +54,8 @@ if (!isset($DEBUG)) { } $securePagesArray = array(); define('SECURE_PAGES', serialize($securePagesArray)); -$nonMobilePagesArray = array(); -define('NON_MOBILE_PAGES', serialize($nonMobilePagesArray)); +$topLevelPages = array(13, 14, 15, 10); +define('TOP_LEVEL_PAGES', serialize($topLevelPages)); /** * URI used for the root of the site */