Home › Forums › WoodMart support forum › Gallery Thumbnail Size Issue
Gallery Thumbnail Size Issue
- This topic has 3 replies, 2 voices, and was last updated 1 year, 7 months ago by Elise Noromit.
-
AuthorPosts
-
May 16, 2023 at 5:15 am #467171
faheem ahmedParticipantHi Team,
On my website, the Gallery Thumbnails Images on the product page download (by right click on the gallery thumbnail and opening in the new tab) with the dimensions of the “Main image width” of 800 pixels instead of the actual width size provided on the WoodMart Theme Settings > Single product > Images > Thumbnails image width 200 pixels when browsing on Google Chrome browser but download the right image width when browsing on Firefox. Get the same big-size images when testing on GTmetrix. ( https://gtmetrix.com/reports/ebag.ca/rDav7OU5/ )
Also if I de-activate Woodmart theme and activate twentytwentythree theme then on both browsers the thumbnail image size is right and not 800 pixels.Kindly look into it and please let me know how to manage this issue.
Thanks in advance
FaheemAttachments:
You must be logged in to view attached files.May 17, 2023 at 1:54 am #467487
Elise NoromitMemberHello,
Woocommerce by default crops images, you can find more details on this forum: https://wordpress.org/support/topic/gallery-thumbnails-size-of-single-product-page/
WoodMart theme just allows changing the size of gallery items.
Please check the issue on the Storefront theme to detect if Woodmart causes any problems.
Best Regards
May 17, 2023 at 6:39 am #467526
faheem ahmedParticipantHi Elise,
I’ve installed the Storefront theme and the gallery thumbnail images have the right size 100×100.
Please see the attached screenshot of the thumbnail and the image size appearing in GTmetrix test. (https://gtmetrix.com/reports/ebag.ca/ST3bitbw/)You already have the admin credentials so please look into the problem because in Woodmart the gallery thumbnail images are appearing of the size of “Full Size image” having main image width i.e 800 pixels.
Attachments:
You must be logged in to view attached files.May 19, 2023 at 2:18 am #468172
Elise NoromitMemberHello,
The images reduces due to scrset here is the documentation: https://developer.mozilla.org/en-US/docs/Learn/HTML/Multimedia_and_embedding/Responsive_images.
You can deactivate it, at the same time we do not recommend doing that.
If you still want to do it, here is the code:
function wd_disable_wp_responsive_images() { return 1; } add_action( 'woocommerce_gallery_thumbnail_size', function () { add_filter('max_srcset_image_width', 'wd_disable_wp_responsive_images'); }); add_action( 'elementor/frontend/widget/after_render', function ( $element ) { remove_filter('max_srcset_image_width', 'wd_disable_wp_responsive_images'); });
You need to add the code to the functions.php of the child theme.
Best Regards
-
AuthorPosts
- You must be logged in to create new topics. Login / Register