General Discussion

Gallery macro display format help!

Selezen ·
Hi there again.

I'm trying to create a gallery format that will allow reading of the image summaries alongside the image but with the images loading in from left to right then top to bottom. Kind of like this:

| Image 1 | Image 2 | Image 3 |

| Image 4 | Image 5 | Image 6 |

| Image 7 | Image 8 | Image 9 |

And so on.

What is currently happening is this:

| Image 1 | Image 4 | Image 7 |

| Image 2 | Image 5 | Image 8 |

| Image 3 | Image 6 | Image 9 |

I've had to use the inline gallery macro {gallery-album id="11" max="25"} because this is the only way I could see to show the images in a thumbnail and have any control over the positioning, as the other options insisted on showing the images in irregular shapes and with the image title over the image and summary (main gallery style) or showing each image the full width of the screen (slideshow).

I've managed to customise the macro template (manually, because I can't find a way to allow the modification of item settings through the meta macro) to show the summary, but I cannot see how to reformat the display images so that they display row by row instead of the default column by column fashion.

Any help here would be appreciated

prana ·
Hi Selezen,

We did have a look at this a while ago and were thinking along the same line. However, in order to reduce the size, we decided to just use as minimal javascript as possible and let the owner to decide which script best suits the purpose.

The entire layout can be replaced completely (by copying it to the /web/{your-site-name}/themes/{your-theme-name}/macros/gallery/view.gallery.template.php .. there's also a sample in /system/macros/gallery/sample.view.gallery.template.php and you can adjust it for any javascript masonry library like in https://morioh.com/p/6dddf25fead3

Hope this helps ...