This topic has 4 replies, 2 voices, and was last updated 1 years ago ago by Rose Tyler
Hello, I hope you are well
I want the product images for the computer to be as follows, which is currently active:
https://drive.google.com/file/d/1aUouTt_SD8j-QRaiDpCnsRNZYyJ5M6Z3/view?usp=sharing
But in mobile mode it should be as follows:
https://drive.google.com/file/d/1apIcATQYOKuMcV4-vCM-VeXvCnyq1gpR/view?usp=sharing
I saw several sites that have this feature
And I know that it is possible to create this feature with Elementor page builder
But can you add this to the theme xstore?
to choose for mobile and computer mode
Hello, MAHDAR,
Thank you for contacting us and for using XStore.
We kindly request that you attempt the solution provided in the following discussion: https://www.8theme.com/topic/problems-variation-swatches-design-cart-button-radius-mobile-devices/#post-356325
Kind Regards,
8theme team
add_action(‘wp’, function() {
add_filter(‘theme_mod_product_gallery_type_et-desktop’, function($value) {
return wp_is_mobile() ? ‘thumbnails_bottom’ : $value;
});
}, 70);
I put this code but it didn’t work
I will send the permissions, please check
Thankful
Hello, MAHDAR,
We have updated the code https://prnt.sc/WRz1oddZFLr8 to
add_action('wp', function() {
add_filter('theme_mod_product_gallery_type_et-desktop', function($value) {
return wp_is_mobile() ? 'thumbnails_bottom' : $value;
}, 999);
}, 70);
With this change implemented, the functionality is now operating correctly for logged-in users. However, we have noticed that it may not be working as intended for users in incognito mode. This could potentially be resolved by clearing the cache or checking the CDN settings, as the wp_is_mobile()
function can sometimes have issues when working with cached content.
Kind Regards,
8theme team
The issue related to '‘Gallery images on mobile and computer’' has been successfully resolved, and the topic is now closed for further responses