ILIAS  release_8 Revision v8.24
with_sections.php
Go to the documentation of this file.
1<?php
2
3declare(strict_types=1);
4
6
7function with_sections()
8{
9 //Init Factory and Renderer
10 global $DIC;
11 $f = $DIC->ui()->factory();
12 $renderer = $DIC->ui()->renderer();
13
14 $content = $f->listing()->descriptive(
15 array(
16 "Entry 1" => "Some text",
17 "Entry 2" => "Some more text",
18 )
19 );
20
21 $image = $f->image()->responsive(
22 "./templates/default/images/HeaderIcon.svg",
23 "Thumbnail Example"
24 );
25
26 $card = $f->card()->standard(
27 "Title",
28 $image
29 )->withSections(
30 array(
31 $content,
32 $content,
33 $content
34 )
35 );
36
37 //Render
38 return $renderer->render($card);
39}
global $DIC
Definition: feed.php:28