Improving navigation between slideshows

Hello everybody,
First of all, this is my first post on this new forum.

I need a little help to improve navigation between slideshows : when we get to the last picture of the slideshow#1, I would like the “next” button becomes “next slideshow” button with a link to the slideshow#2.
And when we are on the first image of the slideshow#2, the “prev” button becomes “prev slideshow” button with a link to the slideshow #1.
This is an example of what i try yo do (without transition effects to slideshows to another):

Here is a link to the actual slideshow:

I do not know how to identify the presence of the first or last image.

Could someone help me?

What happens if you call $file->next() on the last image?

$page->prev()->url() and $page->next()->url() return the url of the previous/next page.

Simply replace the slideshow’s prev/next button on the first/last slide with a link to the previous/next slideshow.

1 Like

You can check for for $files->last()/$files->first() and then go to the next slideshow.

1 Like


Thank you for your answers.

Seems that the slideshow I use (OWL carousel) dont allow to detect the first or last image with $files->last()/$files->first()

$page->prev()->url()/$page->next()->url() works, but i would like it to appear only when we are on first or last image

I think it’s possible to create a new template with $pagination, calling one picture per page, then using $pagination options



A test with pages :


Error 403
It seems the directory is private, or something.

New link :