-
AuthorPosts
-
March 17, 2020 at 2:23 am #1193706
Hi there,
I’m hoping there is a quick fix that doesn’t involve an image optimization plugin for my site. We currently are using the masonary gallery to display images on our site. The masonary is showing thumbnails at twice the size. So an image that appears 343 wide on the front end is actually 705 wide. Then it lightboxes to full size. I’m wondering if there is a way for an image that is only appearing at 343 to actually be closer to 400 px wide vs over 700. What about regenerating thumbnails?
Jaime
March 17, 2020 at 3:57 pm #1193828Hi jaimemerz,
To optimize the size of the masonry, you’ll need to do the following:
– Use a child theme, skip this step if you already are using a child theme, if not then you can follow the instructions and download it in: https://kriesi.at/documentation/enfold/child-theme/
– In the child theme’s functions.php, add this code at the bottom:function enfold_customization_modify_thumb_size( $size ) { $size['masonry'] = array('width'=>400, 'height'=>705 , 'crop' => false); return $size; } add_filter( 'avf_modify_thumb_size', 'enfold_customization_modify_thumb_size', 10, 1 );
Hope this helps.
Best regards,
NikkoMarch 20, 2020 at 12:24 am #1194639Hi there,
Tried this, but am still getting a slow load and poor grades. I’m still seeing large images, too. See attached.
Any other ideas?
Jaime
March 20, 2020 at 5:08 am #1194688Hi Jaime,
You’ll need to regenerate old images since it only affects images uploaded after the code is added.
In the Plugins find Regenerate Thumbnails and regenerate images (you can use other regeneration plugin if you like).Best regards,
NikkoMarch 20, 2020 at 8:33 pm #1194923Hi Nikko,
Thanks so much for your help with this. Do I need to change the size of the thumbnails in the media settings before I regenerate or will the code you’ve provided be sufficient?
Jaime
March 21, 2020 at 5:35 am #1195011Hi Jaime,
You’re very much welcome :)
If you only want the masonry size to change then the code is enough, but if you want to change the size shown in Media Settings then you can do that also on top of the code and when you regenerate images it will set image sizes based on the current setting.Best regards,
NikkoMarch 24, 2020 at 12:59 am #1195607Hi again,
We are only using masonry galleries throughout the site. So if I’m reading correctly, the code alone should deliver smaller images and speed up the site. Unfortunately, it’s not. I’m still seeing intrinsic sizes of 470×704 and the gallery itself displaying at half the size.
Maybe the code isn’t working?
Jaime
March 27, 2020 at 11:34 am #1198300Hi Jaime,
We apologize for the delayed response.
The images seems to be coming from a CDN: https://secureservercdn.net/
Can you try to disable it? if it’s not a plugin maybe it’s from your hosting provider.Best regards,
Nikko -
AuthorPosts
- You must be logged in to reply to this topic.