Overview

Packages

  • CONTENIDO
  • Core
    • Authentication
    • Backend
    • Cache
    • CEC
    • Chain
    • ContentType
    • Database
    • Debug
    • Exception
    • Frontend
      • Search
      • URI
      • Util
    • GenericDB
      • Model
    • GUI
      • HTML
    • I18N
    • LayoutHandler
    • Log
    • Security
    • Session
    • Util
    • Validation
    • Versioning
    • XML
  • Module
    • ContentRssCreator
    • ContentSitemapHtml
    • ContentSitemapXml
    • ContentUserForum
    • NavigationTop
    • ScriptCookieDirective
  • mpAutoloaderClassMap
  • None
  • Plugin
    • ContentAllocation
    • CronjobOverview
    • FormAssistant
    • FrontendLogic
    • FrontendUsers
    • Linkchecker
    • ModRewrite
    • Newsletter
    • Repository
      • FrontendNavigation
      • KeywordDensity
    • SearchSolr
    • SmartyWrapper
    • UrlShortener
    • UserForum
    • Workflow
  • PluginManager
  • Setup
    • Form
    • GUI
    • Helper
      • Environment
      • Filesystem
      • MySQL
      • PHP
    • UpgradeJob

Functions

  • navigation_top_filter
  • Overview
  • Package
  • Function
  • Tree
  • Deprecated
  • Todo
 1: <?php
 2: 
 3: /**
 4:  * description: top navigation
 5:  *
 6:  * @package Module
 7:  * @subpackage NavigationTop
 8:  * @author marcus.gnass@4fb.de
 9:  * @copyright four for business AG <www.4fb.de>
10:  * @license http://www.contenido.org/license/LIZENZ.txt
11:  * @link http://www.4fb.de
12:  * @link http://www.contenido.org
13:  */
14: 
15: // assert framework initialization
16: defined('CON_FRAMEWORK') || die('Illegal call: Missing framework initialization - request aborted.');
17: 
18: // get client settings
19: $rootIdcat = getEffectiveSetting('navigation_top', 'idcat', 1);
20: $depth = getEffectiveSetting('navigation_top', 'depth', 3);
21: 
22: // get category tree
23: $categoryHelper = cCategoryHelper::getInstance();
24: $categoryHelper->setAuth(cRegistry::getAuth());
25: $tree = $categoryHelper->getSubCategories($rootIdcat, $depth);
26: 
27: // get path (breadcrumb) of current category
28: if (!function_exists("navigation_top_filter")) {
29:     /**
30:      *
31:      * @param cApiCategoryLanguage $categoryLanguage
32:      * @return int
33:      */
34:     function navigation_top_filter(cApiCategoryLanguage $categoryLanguage) {
35:         return $categoryLanguage->get('idcat');
36:     }
37: }
38: $path = array_map('navigation_top_filter', $categoryHelper->getCategoryPath(cRegistry::getCategoryId(), 1));
39: 
40: // use template to display navigation
41: $tpl = cSmartyFrontend::getInstance();
42: $tpl->assign('tree', $tree);
43: $tpl->assign('path', $path);
44: $tpl->display('get.tpl');
45: 
46: ?>
CMS CONTENIDO 4.9.11 API documentation generated by ApiGen 2.8.0