HomeHelpTrac

Changeset 15853 for trunk/templates


Ignore:
Timestamp:
01/08/12 21:36:07 (5 months ago)
Author:
Alexander Trofimov
Message:

Menu - old code removed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/templates/base/scripts/BxBaseFunctions.php

    r15840 r15853  
    530530    } 
    531531 
    532     /** 
    533      * Function will generate site's bottom menu; 
    534      * 
    535      * @return : Html presentation data; 
    536      */ 
    537     function genSiteBottomMenu() { 
    538         if (isset($GLOBALS['bx_profiler'])) $GLOBALS['bx_profiler']->beginMenu('Bottom Menu'); 
    539  
    540         bx_import('BxDolPermalinks'); 
    541  
    542         $sOutputHtml    = null; 
    543         $aLinks         = array(); 
    544         $oPermalinks    = BxDolPermalinks::getInstance(); 
    545  
    546  
    547         // read data from cache file 
    548         $oCache = BxDolDb::getInstance()->getDbCacheObject(); 
    549         $aLinks = $oCache->getData(BxDolDb::getInstance()->genDbCacheKey('sys_menu_bottom')); 
    550         if (null === $aLinks) { 
    551  
    552             $sQuery  = "SELECT * FROM `sys_menu_bottom` ORDER BY `Order`"; 
    553             $rResult = db_res($sQuery); 
    554             while($aItems = mysql_fetch_assoc($rResult)) { 
    555                 $aLinks[] = array( 
    556                     'menu_caption'         => ($aItems['Caption']), 
    557                     'menu_link'             => ( $aItems['Script'] ) ? 'javascript:void(0)' : $oPermalinks -> permalink($aItems['Link']), 
    558                     'extended_action'     => ( $aItems['Script'] ) ? 'onclick="' . $aItems['Script'] . '"' : null, 
    559                     'target'             => ( $aItems['Target'] ) ? 'target="_blank"' : null, 
    560                 ); 
    561             } 
    562  
    563             $oCache->setData (BxDolDb::getInstance()->genDbCacheKey('sys_menu_bottom'), $aLinks); 
    564         } 
    565  
    566         foreach ($aLinks as $iID => $aItem) { 
    567             $aLinks[$iID]['menu_caption'] = _t($aItem['menu_caption']); 
    568         } 
    569         $aTemplateKeys = array( 
    570             'bx_repeat:items' => $aLinks, 
    571         ); 
    572  
    573         $sOutputHtml = $this->_oTemplate->parseHtmlByName( 'menu_bottom.html', $aTemplateKeys ); 
    574  
    575         if (isset($GLOBALS['bx_profiler'])) $GLOBALS['bx_profiler']->endMenu('Bottom Menu'); 
    576  
    577         return $sOutputHtml; 
    578     } 
    579  
    580532    function genNotifyMessage($sMessage, $sDirection = 'left', $isButton = false, $sScript = '') { 
    581533        $sDirStyle = ($sDirection == 'left') ? '' : 'notify_message_none'; 
Note: See TracChangeset for help on using the changeset viewer.