ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
show_a_single_image.php
Go to the documentation of this file.
1<?php
3{
4 global $DIC;
5 $factory = $DIC->ui()->factory();
6 $renderer = $DIC->ui()->renderer();
7 $image = $factory->image()->responsive("src/UI/examples/Image/mountains.jpg", "Image source: https://stocksnap.io, Creative Commons CC0 license");
8 $page = $factory->modal()->lightboxImagePage($image, 'Mountains');
9 $modal = $factory->modal()->lightbox($page);
10 $button = $factory->button()->standard('Show Image', '')
11 ->withOnClick($modal->getShowSignal());
12
13 return $renderer->render([$button, $modal]);
14}
$factory
Definition: metadata.php:43
An exception for terminatinating execution or to throw for unit testing.
global $DIC
Definition: saml.php:7
show_a_single_image()