Confirmation screen class.
More...
Confirmation screen class.
- Author
- Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
- Version
- $Id$
Definition at line 15 of file class.ilConfirmationGUI.php.
◆ __construct()
ilConfirmationGUI::__construct |
( |
| ) |
|
◆ addButton()
ilConfirmationGUI::addButton |
( |
|
$a_txt, |
|
|
|
$a_cmd |
|
) |
| |
|
final |
Set cancel button command and text.
- Parameters
-
string | cancel text |
string | cancel command |
Definition at line 67 of file class.ilConfirmationGUI.php.
69 $this->buttons[] = array(
70 "txt" => $a_txt,
"cmd" => $a_cmd);
◆ addHiddenItem()
ilConfirmationGUI::addHiddenItem |
( |
|
$a_post_var, |
|
|
|
$a_value |
|
) |
| |
◆ addItem()
ilConfirmationGUI::addItem |
( |
|
$a_post_var, |
|
|
|
$a_id, |
|
|
|
$a_text, |
|
|
|
$a_img = "" , |
|
|
|
$a_alt = "" |
|
) |
| |
Add row item.
- Parameters
-
string | name of post variable used for id (e.g. "id[]") |
mixed | id value |
string | item text |
string | item image path |
Definition at line 105 of file class.ilConfirmationGUI.php.
108 $this->item[] = array(
"var" => $a_post_var,
"id" => $a_id,
109 "text" => $a_text,
"img" => $a_img,
"alt" => $a_alt);
112 $this->use_images =
true;
◆ getFormAction()
ilConfirmationGUI::getFormAction |
( |
| ) |
|
|
final |
◆ getHeaderText()
ilConfirmationGUI::getHeaderText |
( |
| ) |
|
◆ getHTML()
ilConfirmationGUI::getHTML |
( |
| ) |
|
|
final |
Get confirmation screen HTML.
- Returns
- string HTML code.
Definition at line 132 of file class.ilConfirmationGUI.php.
References $hidden_item, $lng, getFormAction(), getHeaderText(), ilSubmitButton\getInstance(), and ilUtil\sendQuestion().
138 include_once(
"./Services/Utilities/classes/class.ilConfirmationTableGUI.php");
141 if (count($this->item) > 0)
144 $ctab->setData($this->item);
147 foreach ($this->buttons as $b)
149 $ctab->addCommandButton($b[
"cmd"], $b[
"txt"]);
151 $ctab->addCommandButton($this->confirm_cmd, $this->confirm_txt);
152 $ctab->addCommandButton($this->cancel_cmd, $this->cancel_txt);
156 $ctab->addHiddenInput($hidden_item[
"var"], $hidden_item[
"value"]);
161 $ctab->setFormName($this->form_name);
164 return $ctab->getHTML();
169 $tb->setPreventDoubleSubmission(
true);
171 if($this->hidden_item)
173 require_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
174 foreach($this->hidden_item as $hidden_item)
177 $hiddenInput->setValue($hidden_item[
'value']);
178 $tb->addInputItem($hiddenInput);
181 require_once
'Services/UIComponent/Button/classes/class.ilSubmitButton.php';
183 $confirm->setCommand($this->confirm_cmd);
184 $confirm->setCaption($this->confirm_txt,
false);
187 $cancel->setCommand($this->cancel_cmd);
188 $cancel->setCaption($this->cancel_txt,
false);
190 $tb->addButtonInstance($confirm);
191 $tb->addButtonInstance($cancel);
193 return $tb->getHTML();
getHeaderText()
Get Set header text.
static sendQuestion($a_info="", $a_keep=false)
Send Question to Screen.
◆ setCancel()
ilConfirmationGUI::setCancel |
( |
|
$a_txt, |
|
|
|
$a_cmd |
|
) |
| |
|
final |
◆ setConfirm()
ilConfirmationGUI::setConfirm |
( |
|
$a_txt, |
|
|
|
$a_cmd |
|
) |
| |
|
final |
◆ setFormAction()
ilConfirmationGUI::setFormAction |
( |
|
$a_form_action | ) |
|
|
final |
◆ setFormName()
ilConfirmationGUI::setFormName |
( |
|
$a_name | ) |
|
◆ setHeaderText()
ilConfirmationGUI::setHeaderText |
( |
|
$a_headertext | ) |
|
◆ $buttons
ilConfirmationGUI::$buttons = array() |
|
private |
◆ $form_name
ilConfirmationGUI::$form_name |
|
private |
◆ $hidden_item
ilConfirmationGUI::$hidden_item = array() |
|
private |
◆ $item
ilConfirmationGUI::$item = array() |
|
private |
◆ $use_images
ilConfirmationGUI::$use_images = false |
|
private |
The documentation for this class was generated from the following file: