Does anyone know how to to pre-load a large amount of images with in the Gallery.
When selecting the Gallery it takes an age to load all the images.
We are using the latest cmcms 1.12.1 and Gallery 2.0.2
Thanks for any help
Gallery Large Amount of Images
Re: Gallery Large Amount of Images
Use the Gallery pagination for this.
Or use endless scrolling http://www.cmscanbesimple.org/blog/cmsm ... -scrolling
Or use endless scrolling http://www.cmscanbesimple.org/blog/cmsm ... -scrolling
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Re: Gallery Large Amount of Images
Not sure what you mean by 'preloading'.Barrowboy wrote:Does anyone know how to to pre-load a large amount of images with in the Gallery.
When selecting the Gallery it takes an age to load all the images.
We are using the latest cmcms 1.12.1 and Gallery 2.0.2
Thanks for any help
I guess you can preload images when you display a page with none, one or only a few images. If the page (html source) contains more 'links' to the rest of the images AND the (js) logic to preload that could work.
This suggests that you display all images on the page (that's why it takes long) but don't think there's a way to preload.When selecting the Gallery it takes an age to load all the images.
Re: Gallery Large Amount of Images
In stead of pre-loading, take a look at lazy loading: only load the visible images. https://plugins.jquery.com/lazyload/
You can find an example here: http://tinyurl.com/q72rnmu
It is easy to integrate this in a Gallery template.
You can find an example here: http://tinyurl.com/q72rnmu
It is easy to integrate this in a Gallery template.
Re: Gallery Large Amount of Images
Hi All
Thanks for your suggestions.
Just to explain a little more, we have over 1000 images in one gallery on a gallery page, these are paginated into 30 images per page.
I idea of a pre load would be that on first visiting to the site the images would load from the home page in the background thereby when selecting the gallery page there would be no delay or very little.
I will take a look at the lazy load plug to see if that would help.
Thanks
Thanks for your suggestions.
Just to explain a little more, we have over 1000 images in one gallery on a gallery page, these are paginated into 30 images per page.
I idea of a pre load would be that on first visiting to the site the images would load from the home page in the background thereby when selecting the gallery page there would be no delay or very little.
I will take a look at the lazy load plug to see if that would help.
Thanks
Re: Gallery Large Amount of Images
I'm certainly not an expert on this subject
Do you realize that, depending on chosen method and implementation, this could increase data usage a lot? Because users that visit your homepage will (at least) download 30 (and in worst case implementation 1000) images while you're not sure they will actually visit the gallery.
Then, if they do visit the gallery is it sure, or very likely, they start at page one?
I do think there are some methods to let a browser load images into the browser's cache. Probably you need to use the pagination logic to know which images (next 30?) to pre-load. And I think it would involve some ajax to actually get the 'links' to the next 30 images.
Do you realize that, depending on chosen method and implementation, this could increase data usage a lot? Because users that visit your homepage will (at least) download 30 (and in worst case implementation 1000) images while you're not sure they will actually visit the gallery.
Then, if they do visit the gallery is it sure, or very likely, they start at page one?
I do think there are some methods to let a browser load images into the browser's cache. Probably you need to use the pagination logic to know which images (next 30?) to pre-load. And I think it would involve some ajax to actually get the 'links' to the next 30 images.





