ILIAS  release_8 Revision v8.24
base.php
Go to the documentation of this file.
1<?php
2
3declare(strict_types=1);
4
6
7function base()
8{
9 global $DIC;
10 $factory = $DIC->ui()->factory();
11 $renderer = $DIC->ui()->renderer();
12
13 $message = 'Here you see an interruptive Item:';
14 $icon = $factory->image()->standard('./templates/default/images/icon_crs.svg', '');
15 $modal = $factory->modal()->interruptive('My Title', $message, "#")
16 ->withAffectedItems(array(
17 $factory->modal()->interruptiveItem(
18 '10',
19 'Title of the Item',
20 $icon,
21 'Note, this item is currently only to be used in interruptive Modal.'
22 ),
23 $factory->modal()->interruptiveItem(
24 '20',
25 'Title of the other Item',
26 $icon,
27 'And another one.'
28 )
29
30 ));
31 $button = $factory->button()->standard('Show an interruptive Item', '')
32 ->withOnClick($modal->getShowSignal());
33
34
35 return $renderer->render([$button, $modal]);
36}
global $DIC
Definition: feed.php:28
$factory
Definition: metadata.php:75
$message
Definition: xapiexit.php:32