ILIAS  trunk Revision v11.0_alpha-1866-gfa368f7776e
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ILIAS\UI\examples\MessageBox\Success Namespace Reference

Functions

 success ()
 

description: > Example for rendering a success message box. More...

 

Function Documentation

◆ success()

ILIAS\UI\examples\MessageBox\Success\success ( )


description: > Example for rendering a success message box.

expected output: > ILIAS shows a green box with a dummy text and two buttons.

Clicking the buttons will not activate any actions.

Definition at line 33 of file success.php.

References $DIC, Vendor\Package\$f, and $renderer.

Referenced by ilPRGMessageCollection\add(), ilPRGMessageCollection\hasAnyMessages(), and ilPRGMessageCollection\hasSuccess().

34 {
35  global $DIC;
36  $f = $DIC->ui()->factory();
37  $renderer = $DIC->ui()->renderer();
38 
39  $buttons = [$f->button()->standard("Action", "#"), $f->button()->standard("Cancel", "#")];
40 
41  return $renderer->render($f->messageBox()->success("Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.")->withButtons($buttons));
42 }
$renderer
global $DIC
Definition: shib_login.php:22
+ Here is the caller graph for this function: