ILIAS  trunk Revision v11.0_alpha-1753-gb21ca8c4367
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilContainerStartObjectsContentGUI Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Collaboration diagram for ilContainerStartObjectsContentGUI:

Public Member Functions

 __construct (ilContainerGUI $a_gui, ilContainer $a_parent_obj)
 
 enableDesktop (bool $a_value, ilContainerGUI $a_parent_gui)
 
 getHTML ()
 

Protected Member Functions

 getPageHTML ()
 

Protected Attributes

ilGlobalTemplateInterface $tpl
 
ilLanguage $lng
 
ilSetting $settings
 
ilObjUser $user
 
ilContainerStartObjects $start_object
 
bool $enable_desktop
 
ilContainerGUI $parent_gui
 
ilContainer $parent_obj
 
ILIAS Style Content GUIService $content_style_gui
 
ILIAS Style Content Object ObjectFacade $content_style_domain
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Class ilContainerStartObjectsContentGUI

Author
Jörg Lützenkirchen luetz.nosp@m.enki.nosp@m.rchen.nosp@m.@lei.nosp@m.fos.c.nosp@m.om

Definition at line 24 of file class.ilContainerStartObjectsContentGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilContainerStartObjectsContentGUI::__construct ( ilContainerGUI  $a_gui,
ilContainer  $a_parent_obj 
)

Definition at line 37 of file class.ilContainerStartObjectsContentGUI.php.

References $DIC, ilObject\getId(), ilObject\getRefId(), ILIAS\Repository\lng(), ILIAS\Repository\settings(), and ILIAS\Repository\user().

40  {
41  global $DIC;
42 
43  $this->tpl = $DIC["tpl"];
44  $this->lng = $DIC->language();
45  $this->settings = $DIC->settings();
46  $this->user = $DIC->user();
47  $this->parent_gui = $a_gui;
48  $this->parent_obj = $a_parent_obj;
49  $this->start_object = new ilContainerStartObjects(
50  $a_parent_obj->getRefId(),
51  $a_parent_obj->getId()
52  );
53  $cs = $DIC->contentStyle();
54  $this->content_style_domain = $cs->domain()->styleForRefId($a_parent_obj->getRefId());
55  $this->content_style_gui = $cs->gui();
56  }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
global $DIC
Definition: shib_login.php:22
+ Here is the call graph for this function:

Member Function Documentation

◆ enableDesktop()

ilContainerStartObjectsContentGUI::enableDesktop ( bool  $a_value,
ilContainerGUI  $a_parent_gui 
)

Definition at line 58 of file class.ilContainerStartObjectsContentGUI.php.

61  : void {
62  $this->enable_desktop = $a_value;
63 
64  if ($this->enable_desktop) {
65  $this->parent_gui = $a_parent_gui;
66  }
67  }

◆ getHTML()

ilContainerStartObjectsContentGUI::getHTML ( )

Definition at line 70 of file class.ilContainerStartObjectsContentGUI.php.

References $lng, $tpl, getPageHTML(), ilLanguage\loadLanguageModule(), and ILIAS\UICore\GlobalTemplate\setContent().

70  : void
71  {
72  $tpl = $this->tpl;
73  $lng = $this->lng;
74 
75  $lng->loadLanguageModule("crs");
76 
78  $this->parent_gui,
79  "",
80  $this->start_object,
81  $this->enable_desktop
82  );
84  $this->getPageHTML() .
85  $tbl->getHTML()
86  );
87  }
setContent(string $a_html)
Sets content for standard template.
loadLanguageModule(string $a_module)
Load language module.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the call graph for this function:

◆ getPageHTML()

ilContainerStartObjectsContentGUI::getPageHTML ( )
protected

Definition at line 89 of file class.ilContainerStartObjectsContentGUI.php.

References $ilSetting, $settings, $tpl, ilPageUtil\_existsAndNotEmpty(), ilObjStyleSheet\getSyntaxStylePath(), ILIAS\UICore\GlobalTemplate\parseCurrentBlock(), ILIAS\UICore\GlobalTemplate\setCurrentBlock(), and ILIAS\UICore\GlobalTemplate\setVariable().

Referenced by getHTML().

89  : string
90  {
91  $tpl = $this->tpl;
93 
94  if (!$ilSetting->get("enable_cat_page_edit")) {
95  return "";
96  }
97 
98  $page_id = $this->start_object->getObjId();
99 
100  // if page does not exist, return nothing
101  if (!ilPageUtil::_existsAndNotEmpty("cstr", $page_id)) {
102  return "";
103  }
104 
105  $this->content_style_gui->addCss($tpl, $this->parent_obj->getRefId());
106  $tpl->setCurrentBlock("SyntaxStyle");
107  $tpl->setVariable(
108  "LOCATION_SYNTAX_STYLESHEET",
110  );
112 
113  $page_gui = new ilContainerStartObjectsPageGUI($page_id);
114 
115  $page_gui->setStyleId($this->content_style_domain->getEffectiveStyleId());
116 
117  $page_gui->setPresentationTitle("");
118  $page_gui->setTemplateOutput(false);
119  $page_gui->setHeader("");
120  return $page_gui->showPage();
121  }
parseCurrentBlock(string $block_name=self::DEFAULT_BLOCK)
Parses the given block.
Container start objects page GUI class.
setCurrentBlock(string $part=self::DEFAULT_BLOCK)
Sets the template to the given block.
setVariable(string $variable, $value='')
Sets the given variable to the given value.
static _existsAndNotEmpty(string $a_parent_type, int $a_id, string $a_lang="-")
checks whether page exists and is not empty (may return true on some empty pages) ...
global $ilSetting
Definition: privfeed.php:31
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $content_style_domain

ILIAS Style Content Object ObjectFacade ilContainerStartObjectsContentGUI::$content_style_domain
protected

Definition at line 35 of file class.ilContainerStartObjectsContentGUI.php.

◆ $content_style_gui

ILIAS Style Content GUIService ilContainerStartObjectsContentGUI::$content_style_gui
protected

Definition at line 34 of file class.ilContainerStartObjectsContentGUI.php.

◆ $enable_desktop

bool ilContainerStartObjectsContentGUI::$enable_desktop
protected

Definition at line 31 of file class.ilContainerStartObjectsContentGUI.php.

◆ $lng

ilLanguage ilContainerStartObjectsContentGUI::$lng
protected

Definition at line 27 of file class.ilContainerStartObjectsContentGUI.php.

Referenced by getHTML().

◆ $parent_gui

ilContainerGUI ilContainerStartObjectsContentGUI::$parent_gui
protected

Definition at line 32 of file class.ilContainerStartObjectsContentGUI.php.

◆ $parent_obj

ilContainer ilContainerStartObjectsContentGUI::$parent_obj
protected

Definition at line 33 of file class.ilContainerStartObjectsContentGUI.php.

◆ $settings

ilSetting ilContainerStartObjectsContentGUI::$settings
protected

Definition at line 28 of file class.ilContainerStartObjectsContentGUI.php.

Referenced by getPageHTML().

◆ $start_object

ilContainerStartObjects ilContainerStartObjectsContentGUI::$start_object
protected

Definition at line 30 of file class.ilContainerStartObjectsContentGUI.php.

◆ $tpl

ilGlobalTemplateInterface ilContainerStartObjectsContentGUI::$tpl
protected

Definition at line 26 of file class.ilContainerStartObjectsContentGUI.php.

Referenced by getHTML(), and getPageHTML().

◆ $user

ilObjUser ilContainerStartObjectsContentGUI::$user
protected

Definition at line 29 of file class.ilContainerStartObjectsContentGUI.php.


The documentation for this class was generated from the following file: