21 protected $type = self::TYPE_MEDIUM;
68 $this->heading = $a_val;
108 $this->type = $a_val;
128 $this->buttons[] = $but;
149 $tpl =
new ilTemplate(
"tpl.modal.html",
true,
true,
"Services/UIComponent/Modal");
153 $tpl->setCurrentBlock(
"button");
154 $tpl->setVariable(
"BUTTON", $b->render());
155 $tpl->parseCurrentBlock();
157 $tpl->setCurrentBlock(
"footer");
158 $tpl->parseCurrentBlock();
163 $tpl->setVariable(
"MOD_ID", $this->
getId());
167 case self::TYPE_LARGE:
168 $tpl->setVariable(
"CLASS",
"modal-lg");
171 case self::TYPE_SMALL:
172 $tpl->setVariable(
"CLASS",
"modal-sm");
186 if ($a_main_tpl != null) {
192 $tpl->addJavascript(
"./Services/UIComponent/Modal/js/Modal.js");
static initJS(ilTemplate $a_main_tpl=null)
Init javascript.
__construct()
Constructor.
addButton(ilButtonBase $but)
Add button.
special template class to simplify handling of ITX/PEAR
static getInstance()
Get instance.
setHeading($a_val)
Set heading.