ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
show_multiple_images.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', 'Nice view on some mountains');
8  $page = $factory->modal()->lightboxImagePage($image, 'Mountains', 'Image source: https://stocksnap.io, Creative Commons CC0 license');
9  $image2 = $factory->image()->responsive('src/UI/examples/Image/sanfrancisco.jpg', 'The golden gate bridge');
10  $page2 = $factory->modal()->lightboxImagePage($image2, 'San Francisco', 'Image source: https://stocksnap.io, Creative Commons CC0 license');
11  $image3 = $factory->image()->responsive('src/UI/examples/Image/ski.jpg', 'Skiing');
12  $page3 = $factory->modal()->lightboxImagePage($image3, 'Ski Fun', 'Image source: https://stocksnap.io, Creative Commons CC0 license');
13  $modal = $factory->modal()->lightbox([$page, $page2, $page3]);
14  $button = $factory->button()->standard('Show some fancy images', '')
15  ->withOnClick($modal->getShowSignal());
16 
17  return $renderer->render([$button, $modal]);
18 }
global $DIC
Definition: saml.php:7
$factory
Definition: metadata.php:43
show_multiple_images()