Overview

Packages

  • Core
    • Authentication
    • Backend
    • Cache
    • CEC
    • Chain
    • ContentType
    • Database
    • Datatype
    • Debug
    • Exception
    • Frontend
      • Search
      • URI
      • Util
    • GenericDB
      • Model
    • GUI
      • HTML
    • I18N
    • LayoutHandler
    • Log
    • Security
    • Session
    • Util
    • Validation
    • Versioning
    • XML
  • Module
    • ContentSitemapHtml
    • ContentSitemapXml
    • ContentUserForum
    • NavigationMain
    • NavigationTop
  • 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

Classes

  • cCodeGeneratorAbstract
  • cCodeGeneratorFactory
  • cCodeGeneratorStandard
  • cContentTypeAbstract
  • cContentTypeAbstractTabbed
  • cContentTypeDate
  • cContentTypeFilelist
  • cContentTypeHead
  • cContentTypeHtml
  • cContentTypeHtmlhead
  • cContentTypeImg
  • cContentTypeImgdescr
  • cContentTypeImgeditor
  • cContentTypeLink
  • cContentTypeLinkdescr
  • cContentTypeLinkeditor
  • cContentTypeLinktarget
  • cContentTypeTeaser
  • cContentTypeText
  • cTypeGenerator
  • Overview
  • Package
  • Class
  • Tree
  • Deprecated
  • Todo
 1: <?php
 2: /**
 3:  * This file contains the cContentTypeAbstractTabbed class.
 4:  *
 5:  * @package Core
 6:  * @subpackage ContentType
 7:  * @version SVN Revision $Rev:$
 8:  *
 9:  * @author Simon Sprankel
10:  * @copyright four for business AG <www.4fb.de>
11:  * @license http://www.contenido.org/license/LIZENZ.txt
12:  * @link http://www.4fb.de
13:  * @link http://www.contenido.org
14:  */
15: 
16: defined('CON_FRAMEWORK') || die('Illegal call: Missing framework initialization - request aborted.');
17: 
18: /**
19:  * Abstract content type for content types which are edited in a tabbed popup.
20:  *
21:  * @package Core
22:  * @subpackage ContentType
23:  */
24: abstract class cContentTypeAbstractTabbed extends cContentTypeAbstract {
25: 
26:     /**
27:      * Generates the encoded code for the tab menu.
28:      *
29:      * @param array $tabs associative array mapping the tab IDs to the tab names
30:      * @return string - the encoded code for the tab menu
31:      */
32:     protected function _generateTabMenuCode(array $tabs) {
33:         $template = new cTemplate();
34: 
35:         // iterate over all tabs and set dynamic template placeholder for each
36:         foreach ($tabs as $id => $name) {
37:             $template->set('d', 'TAB_ID', $id);
38:             $template->set('d', 'TAB_NAME', $name);
39:             $template->next();
40:         }
41:         $code = $template->generate($this->_cfg['path']['contenido'] . 'templates/standard/template.cms_abstract_tabbed_edit_tab_menu.html', true);
42: 
43:         return $this->_encodeForOutput($code);
44:     }
45: 
46:     /**
47:      * Generates the code for the action buttons (save and cancel).
48:      *
49:      * @return string - the encoded code for the action buttons
50:      */
51:     protected function _generateActionCode() {
52:         $template = new cTemplate();
53: 
54:         $template->set('s', 'CON_PATH', $this->_cfg['path']['contenido_fullhtml']);
55:         $code = $template->generate($this->_cfg['path']['contenido'] . 'templates/standard/template.cms_abstract_tabbed_edit_action.html', true);
56: 
57:         return $this->_encodeForOutput($code);
58:     }
59: 
60: }
CMS CONTENIDO 4.9.0 API documentation generated by ApiGen 2.8.0