Confirmation screen class.
More...
|
| __construct () |
| Constructor. More...
|
|
| setFormAction ($a_form_action) |
|
| getFormAction () |
|
| setHeaderText ($a_headertext) |
| Set Set header text. More...
|
|
| getHeaderText () |
| Get Set header text. More...
|
|
| addButton ($a_txt, $a_cmd) |
| Set cancel button command and text. More...
|
|
| setCancel ($a_txt, $a_cmd, $a_id="") |
| Set cancel button command and text. More...
|
|
| setConfirm ($a_txt, $a_cmd, $a_id="") |
| Set confirmation button command and text. More...
|
|
| addItem ( $a_post_var, $a_id, $a_text, $a_img="", $a_alt="") |
| Add row item. More...
|
|
| addHiddenItem ($a_post_var, $a_value) |
| Add hidden item. More...
|
|
| getHTML () |
| Get confirmation screen HTML. More...
|
|
| setFormName ($a_name) |
| Set form name. 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 75 of file class.ilConfirmationGUI.php.
77 $this->buttons[] = array(
78 "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 115 of file class.ilConfirmationGUI.php.
122 $this->item[] = array(
"var" => $a_post_var,
"id" => $a_id,
123 "text" => $a_text,
"img" => $a_img,
"alt" => $a_alt);
125 $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 145 of file class.ilConfirmationGUI.php.
References Vendor\Package\$b, $hidden_item, $lng, getFormAction(), getHeaderText(), ilSubmitButton\getInstance(), and ilUtil\sendQuestion().
151 include_once(
"./Services/Utilities/classes/class.ilConfirmationTableGUI.php");
154 if (count($this->item) > 0) {
156 $ctab->setData($this->item);
159 foreach ($this->buttons as
$b) {
160 $ctab->addCommandButton($b[
"cmd"], $b[
"txt"]);
162 $ctab->addCommandButton($this->confirm_cmd, $this->confirm_txt);
163 $ctab->addCommandButton($this->cancel_cmd, $this->cancel_txt);
166 $ctab->addHiddenInput($hidden_item[
"var"], $hidden_item[
"value"]);
169 if ($this->form_name) {
170 $ctab->setFormName($this->form_name);
173 return $ctab->getHTML();
176 $tb->setPreventDoubleSubmission(
true);
178 if ($this->hidden_item) {
179 require_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
180 foreach ($this->hidden_item as $hidden_item) {
182 $hiddenInput->setValue($hidden_item[
'value']);
183 $tb->addInputItem($hiddenInput);
186 require_once
'Services/UIComponent/Button/classes/class.ilSubmitButton.php';
188 $confirm->setCommand($this->confirm_cmd);
189 $confirm->setCaption($this->confirm_txt,
false);
190 $confirm->setId($this->confirm_id);
193 $cancel->setCommand($this->cancel_cmd);
194 $cancel->setCaption($this->cancel_txt,
false);
195 $cancel->setId($this->cancel_id);
197 $tb->addStickyItem($confirm);
198 $tb->addStickyItem($cancel);
200 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, |
|
|
|
$a_id = "" |
|
) |
| |
|
final |
◆ setConfirm()
ilConfirmationGUI::setConfirm |
( |
|
$a_txt, |
|
|
|
$a_cmd, |
|
|
|
$a_id = "" |
|
) |
| |
|
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 |
◆ $lng
◆ $use_images
ilConfirmationGUI::$use_images = false |
|
private |
The documentation for this class was generated from the following file: