Better gallery

Replaced complex gallery with simple script
Slideshow loaded from images/gallery folder
Credits: https://www.w3schools.com/howto/howto_js_slideshow.asp
This commit is contained in:
slawkens
2026-01-31 17:42:59 +01:00
parent fd457b2fe8
commit 8d78e7090d
16 changed files with 191 additions and 438 deletions

View File

@@ -1,14 +1,12 @@
<?php
use MyAAC\Models\Gallery;
if(PAGE !== 'news') {
return;
}
$gallery = Gallery::find($config['gallery_image_id_from_database']);
if ($gallery) {
$configGalleryImageThumb = config('gallery_image_thumb');
if (!empty($configGalleryImageThumb)) {
$twig->display('gallery.html.twig', array(
'image' => $gallery->toArray()
'image' => GALLERY_DIR . $configGalleryImageThumb,
));
}