ILIAS  release_8 Revision v8.24
ilPanelGUI 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 ilPanelGUI:

Public Member Functions

 setHeading (string $a_val)
 
 getHeading ()
 
 setBody (string $a_val)
 
 getBody ()
 
 setFooter (string $a_val)
 
 getFooter ()
 
 setPanelStyle (int $a_val)
 
 getPanelStyle ()
 
 setHeadingStyle (int $a_val)
 
 getHeadingStyle ()
 
 setFooterStyle (int $a_val)
 
 getFooterStyle ()
 
 getHTML ()
 

Static Public Member Functions

static getInstance ()
 

Data Fields

const PANEL_STYLE_PRIMARY = 0
 
const PANEL_STYLE_SECONDARY = 1
 
const HEADING_STYLE_SUBHEADING = 0
 
const HEADING_STYLE_BLOCK = 1
 
const FOOTER_STYLE_BLOCK = 0
 

Protected Member Functions

 __construct ()
 

Protected Attributes

string $heading = ""
 
string $body = ""
 
string $footer = ""
 
int $panel_style = 0
 
int $heading_style = 0
 
int $footer_style = 0
 

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 Simple panel class

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

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

Constructor & Destructor Documentation

◆ __construct()

ilPanelGUI::__construct ( )
protected

Definition at line 39 of file class.ilPanelGUI.php.

40 {
41 }

Member Function Documentation

◆ getBody()

ilPanelGUI::getBody ( )

Definition at line 63 of file class.ilPanelGUI.php.

63 : string
64 {
65 return $this->body;
66 }

References $body.

Referenced by getHTML().

+ Here is the caller graph for this function:

◆ getFooter()

ilPanelGUI::getFooter ( )

Definition at line 73 of file class.ilPanelGUI.php.

73 : string
74 {
75 return $this->footer;
76 }

References $footer.

Referenced by getHTML().

+ Here is the caller graph for this function:

◆ getFooterStyle()

ilPanelGUI::getFooterStyle ( )

Definition at line 103 of file class.ilPanelGUI.php.

103 : int
104 {
105 return $this->footer_style;
106 }

References $footer_style.

Referenced by getHTML().

+ Here is the caller graph for this function:

◆ getHeading()

ilPanelGUI::getHeading ( )

Definition at line 53 of file class.ilPanelGUI.php.

53 : string
54 {
55 return $this->heading;
56 }

References $heading.

Referenced by getHTML().

+ Here is the caller graph for this function:

◆ getHeadingStyle()

ilPanelGUI::getHeadingStyle ( )

Definition at line 93 of file class.ilPanelGUI.php.

93 : int
94 {
96 }

References $heading_style.

Referenced by getHTML().

+ Here is the caller graph for this function:

◆ getHTML()

ilPanelGUI::getHTML ( )

Definition at line 108 of file class.ilPanelGUI.php.

108 : string
109 {
110 $tpl = new ilTemplate("tpl.panel.html", true, true, "Services/UIComponent/Panel");
111
112 $head_outer_div_style = "";
113 if ($this->getHeading() !== "") {
114 $tpl->setCurrentBlock("heading");
115 $tpl->setVariable("HEADING", $this->getHeading());
116
117 switch ($this->getHeadingStyle()) {
119 $tpl->setVariable("HEAD_DIV_STYLE", "panel-heading ilBlockHeader");
120 $tpl->setVariable("HEAD_H3_STYLE", "ilBlockHeader");
121 $head_outer_div_style = "il_Block";
122 break;
123
125 $tpl->setVariable("HEAD_DIV_STYLE", "panel-heading ilHeader");
126 $tpl->setVariable("HEAD_H3_STYLE", "ilHeader");
127 break;
128 }
129
130 $tpl->parseCurrentBlock();
131 }
132
133 $tpl->setVariable("BODY", $this->getBody());
134
135 if ($this->getFooter() !== "") {
136 $tpl->setCurrentBlock("footer");
137 $tpl->setVariable("FOOTER", $this->getFooter());
138
139 switch ($this->getFooterStyle()) {
141 $tpl->setVariable("FOOT_DIV_STYLE", "panel-footer ilBlockInfo");
142 break;
143 }
144
145 $tpl->parseCurrentBlock();
146 }
147
148 switch ($this->getPanelStyle()) {
150 $tpl->setVariable("PANEL_STYLE", "panel panel-default " . $head_outer_div_style);
151 break;
152
153 default:
154 $tpl->setVariable("PANEL_STYLE", "panel panel-primary " . $head_outer_div_style);
155 break;
156 }
157
158 return $tpl->get();
159 }
const PANEL_STYLE_SECONDARY
const HEADING_STYLE_SUBHEADING
const HEADING_STYLE_BLOCK
const FOOTER_STYLE_BLOCK
special template class to simplify handling of ITX/PEAR
if($DIC->http() ->request() ->getMethod()=="GET" &&isset($DIC->http() ->request() ->getQueryParams()['tex'])) $tpl
Definition: latex.php:41

References $tpl, FOOTER_STYLE_BLOCK, getBody(), getFooter(), getFooterStyle(), getHeading(), getHeadingStyle(), getPanelStyle(), HEADING_STYLE_BLOCK, HEADING_STYLE_SUBHEADING, and PANEL_STYLE_SECONDARY.

+ Here is the call graph for this function:

◆ getInstance()

◆ getPanelStyle()

ilPanelGUI::getPanelStyle ( )

Definition at line 83 of file class.ilPanelGUI.php.

83 : int
84 {
85 return $this->panel_style;
86 }

References $panel_style.

Referenced by getHTML().

+ Here is the caller graph for this function:

◆ setBody()

ilPanelGUI::setBody ( string  $a_val)

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

58 : void
59 {
60 $this->body = $a_val;
61 }

◆ setFooter()

ilPanelGUI::setFooter ( string  $a_val)

Definition at line 68 of file class.ilPanelGUI.php.

68 : void
69 {
70 $this->footer = $a_val;
71 }

References ILIAS\UI\examples\MainControls\Footer\footer().

+ Here is the call graph for this function:

◆ setFooterStyle()

ilPanelGUI::setFooterStyle ( int  $a_val)

Definition at line 98 of file class.ilPanelGUI.php.

98 : void
99 {
100 $this->footer_style = $a_val;
101 }

◆ setHeading()

ilPanelGUI::setHeading ( string  $a_val)

Definition at line 48 of file class.ilPanelGUI.php.

48 : void
49 {
50 $this->heading = $a_val;
51 }

◆ setHeadingStyle()

ilPanelGUI::setHeadingStyle ( int  $a_val)

Definition at line 88 of file class.ilPanelGUI.php.

88 : void
89 {
90 $this->heading_style = $a_val;
91 }

◆ setPanelStyle()

ilPanelGUI::setPanelStyle ( int  $a_val)

Definition at line 78 of file class.ilPanelGUI.php.

78 : void
79 {
80 $this->panel_style = $a_val;
81 }

Field Documentation

◆ $body

string ilPanelGUI::$body = ""
protected

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

Referenced by getBody().

◆ $footer

string ilPanelGUI::$footer = ""
protected

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

Referenced by getFooter().

◆ $footer_style

int ilPanelGUI::$footer_style = 0
protected

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

Referenced by getFooterStyle().

◆ $heading

string ilPanelGUI::$heading = ""
protected

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

Referenced by getHeading().

◆ $heading_style

int ilPanelGUI::$heading_style = 0
protected

Definition at line 36 of file class.ilPanelGUI.php.

Referenced by getHeadingStyle().

◆ $panel_style

int ilPanelGUI::$panel_style = 0
protected

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

Referenced by getPanelStyle().

◆ FOOTER_STYLE_BLOCK

const ilPanelGUI::FOOTER_STYLE_BLOCK = 0

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

Referenced by getHTML().

◆ HEADING_STYLE_BLOCK

const ilPanelGUI::HEADING_STYLE_BLOCK = 1

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

Referenced by getHTML(), and ilChatroomViewGUI\showRoom().

◆ HEADING_STYLE_SUBHEADING

const ilPanelGUI::HEADING_STYLE_SUBHEADING = 0

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

Referenced by ilTestQuestionSideListGUI\buildPanel(), and getHTML().

◆ PANEL_STYLE_PRIMARY

const ilPanelGUI::PANEL_STYLE_PRIMARY = 0

◆ PANEL_STYLE_SECONDARY


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