ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilPanelGUI Class Reference

Simple panel class. More...

+ Collaboration diagram for ilPanelGUI:

Public Member Functions

 setHeading ($a_val)
 Set heading.
 getHeading ()
 Get heading.
 setBody ($a_val)
 Set body.
 getBody ()
 Get body.
 setFooter ($a_val)
 Set footer.
 getFooter ()
 Get body.
 setPanelStyle ($a_val)
 Set panel style.
 getPanelStyle ()
 Get panel style.
 setHeadingStyle ($a_val)
 Set heading style.
 getHeadingStyle ()
 Get heading style.
 setFooterStyle ($a_val)
 Set footer style.
 getFooterStyle ()
 Get footer style.
 getHTML ()
 Get HTML.

Static Public Member Functions

static getInstance ()
 Get instance.

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 ()
 Constructor.

Protected Attributes

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

Detailed Description

Simple panel class.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$ /

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

Constructor & Destructor Documentation

ilPanelGUI::__construct ( )
protected

Constructor.

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

{
}

Member Function Documentation

ilPanelGUI::getBody ( )

Get body.

Returns
string body

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

References $body.

Referenced by getHTML().

{
return $this->body;
}

+ Here is the caller graph for this function:

ilPanelGUI::getFooter ( )

Get body.

Returns
string body

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

References $footer.

Referenced by getHTML().

{
return $this->footer;
}

+ Here is the caller graph for this function:

ilPanelGUI::getFooterStyle ( )

Get footer style.

Returns
int footer style

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

References $footer_style.

Referenced by getHTML().

{
}

+ Here is the caller graph for this function:

ilPanelGUI::getHeading ( )

Get heading.

Returns
string heading

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

References $heading.

Referenced by getHTML().

{
}

+ Here is the caller graph for this function:

ilPanelGUI::getHeadingStyle ( )

Get heading style.

Returns
int heading style

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

References $heading_style.

Referenced by getHTML().

{
}

+ Here is the caller graph for this function:

ilPanelGUI::getHTML ( )

Get HTML.

Returns
string html

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

References $tpl, getBody(), getFooter(), getFooterStyle(), getHeading(), getHeadingStyle(), and getPanelStyle().

{
$tpl = new ilTemplate("tpl.panel.html", true, true, "Services/UIComponent/Panel");
$head_outer_div_style = "";
if ($this->getHeading() != "")
{
$tpl->setCurrentBlock("heading");
$tpl->setVariable("HEADING", $this->getHeading());
switch ($this->getHeadingStyle())
{
case self::HEADING_STYLE_BLOCK:
$tpl->setVariable("HEAD_DIV_STYLE", "panel-heading ilBlockHeader");
$tpl->setVariable("HEAD_H3_STYLE", "ilBlockHeader");
$head_outer_div_style = "il_Block";
break;
case self::HEADING_STYLE_SUBHEADING:
$tpl->setVariable("HEAD_DIV_STYLE", "panel-heading ilHeader");
$tpl->setVariable("HEAD_H3_STYLE", "ilHeader");
break;
}
$tpl->parseCurrentBlock();
}
$tpl->setVariable("BODY", $this->getBody());
if ($this->getFooter() != "")
{
$tpl->setCurrentBlock("footer");
$tpl->setVariable("FOOTER", $this->getFooter());
switch ($this->getFooterStyle())
{
case self::FOOTER_STYLE_BLOCK:
$tpl->setVariable("FOOT_DIV_STYLE", "panel-footer ilBlockInfo");
break;
}
$tpl->parseCurrentBlock();
}
switch ($this->getPanelStyle())
{
case self::PANEL_STYLE_SECONDARY:
$tpl->setVariable("PANEL_STYLE", "panel panel-default ".$head_outer_div_style);
break;
default:
$tpl->setVariable("PANEL_STYLE", "panel panel-primary ".$head_outer_div_style);
break;
}
return $tpl->get();
}

+ Here is the call graph for this function:

ilPanelGUI::getPanelStyle ( )

Get panel style.

Returns
int panel_style

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

References $panel_style.

Referenced by getHTML().

{
}

+ Here is the caller graph for this function:

ilPanelGUI::setBody (   $a_val)

Set body.

Parameters
string$a_valbody

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

{
$this->body = $a_val;
}
ilPanelGUI::setFooter (   $a_val)

Set footer.

Parameters
string$a_valfooter

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

{
$this->footer = $a_val;
}
ilPanelGUI::setFooterStyle (   $a_val)

Set footer style.

Parameters
int$a_valfooter style

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

{
$this->footer_style = $a_val;
}
ilPanelGUI::setHeading (   $a_val)

Set heading.

Parameters
string$a_valheading

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

{
$this->heading = $a_val;
}
ilPanelGUI::setHeadingStyle (   $a_val)

Set heading style.

Parameters
int$a_valheading style

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

{
$this->heading_style = $a_val;
}
ilPanelGUI::setPanelStyle (   $a_val)

Set panel style.

Parameters
int$a_valpanel_style

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

{
$this->panel_style = $a_val;
}

Field Documentation

ilPanelGUI::$body = ""
protected

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

Referenced by getBody().

ilPanelGUI::$footer = ""
protected

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

Referenced by getFooter().

ilPanelGUI::$footer_style = 0
protected

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

Referenced by getFooterStyle().

ilPanelGUI::$heading = ""
protected

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

Referenced by getHeading().

ilPanelGUI::$heading_style = 0
protected

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

Referenced by getHeadingStyle().

ilPanelGUI::$panel_style = 0
protected

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

Referenced by getPanelStyle().

const ilPanelGUI::FOOTER_STYLE_BLOCK = 0

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

const ilPanelGUI::HEADING_STYLE_BLOCK = 1

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

Referenced by ilChecklistGUI\getHTML(), and ilObjBlogGUI\renderNavigation().

const ilPanelGUI::HEADING_STYLE_SUBHEADING = 0
const ilPanelGUI::PANEL_STYLE_PRIMARY = 0

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

Referenced by ilPersonalSkillsGUI\getGapAnalysisHTML().


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