Tagged: gallery, thumbnails
-
AuthorPosts
-
February 17, 2017 at 3:46 pm #748504
Hi guys,
I am using the media element “gallery” on our website and I can´t find a way to limit the number of displayed thumbnails. I have multiple galleries, some with 10, some with 30 images. For all of them I want to limit the number of displayed thumbnails to a maximum of 5. If a user clicks on the image he should be able to view all images in the lightbox. Any idea how to do that?
Thank you in advance!
DanielFebruary 19, 2017 at 9:50 am #748977I found this in a similar post, which unfortunately does not work for me:
#top #wrap_all .avia-gallery .avia-gallery-thumb a:nth-last-child(-n+3) {
display: none !important;
}Unfortunately it only helps, if all of the galleries have the same amount of images, which is not the case. Or do I just not understand the nht-last-child correctly? Any other ideas?
February 22, 2017 at 11:28 am #750413Hi,
Can you post links to the pages mentioned? also can you provide temporary admin account so we can check the backend for the said pages. Please place the login details in Private Content when you reply.
Best regards,
NikkoFebruary 22, 2017 at 1:41 pm #750474Hi Nikko,
attached I send you a link to one of the pages. If you scroll down you see multiple image thumbnail displayed. I want to limit the number of thumbnails, but have the other images available to be displayed in the lightbox.
I appreciate if there is a custom CCS solution.
Thx
DanielFebruary 27, 2017 at 10:37 pm #752574Hi,
Try adding this css code in QUick CSS (located in Enfold > General Styling):
.single-portfolio .avia-gallery-thumb > a { display: none !important; } .single-portfolio .avia-gallery-thumb > a:first-child, .single-portfolio .avia-gallery-thumb > a:nth-child(2), .single-portfolio .avia-gallery-thumb > a:nth-child(3), .single-portfolio .avia-gallery-thumb > a:nth-child(4), .single-portfolio .avia-gallery-thumb > a:nth-child(5), .single-portfolio .avia-gallery-thumb > a:nth-child(6) { display: block !important; }
I’ve made it to show 6 (though you said 5) since it looks better but you can remove the .single-portfolio .avia-gallery-thumb > a:nth-child(6) and the comma (,) before it to make it only 5. Hope this helps.
Best regards,
NikkoFebruary 28, 2017 at 1:09 pm #752905Hi Nikko,
thanks but unfortunately it doesn´t change anything in the gallery thumbnails. Still in all gallerie smore than 6 thumbnails.March 5, 2017 at 1:49 pm #755912Hi,
Sorry for the late response but can you give a link to the page that still has the issue and also a temporary admin account, so we can check the backend, and know why it’s not working.
Best regards,
NikkoMarch 6, 2017 at 10:18 am #756278Hi Nikko,
I removed the section for the gallery in the quick CSS again. Attached you find the temporary admin access. Thanks again for your support on this topic.
DanielMarch 7, 2017 at 1:03 pm #756955Hey guys, already new findings on the topic?
Regards
DanielMarch 9, 2017 at 3:08 pm #758383Hello?? Still there?
March 13, 2017 at 7:37 am #759840Hi Daniel,
I apologize for missing your thread, I have added the css code in Quick CSS in Enfold Child > General Styling, then I cleared the cache from autoptimize plugin and it worked well.
Best regards,
NikkoMarch 13, 2017 at 9:16 am #759874Hi Nikko,
no worries as long as it is working :)
Thank you very much, looks really good.
Cheers
Daniel -
AuthorPosts
- You must be logged in to reply to this topic.