Home › Forums › WoodMart support forum › Single column product page problem
Single column product page problem
- This topic has 42 replies, 4 voices, and was last updated 5 years ago by Artem Temos.
-
AuthorPosts
-
November 11, 2019 at 2:22 pm #156321
horny_fungusParticipantThank you very much for your efforts. Will be waiting.
November 11, 2019 at 2:28 pm #156324
Eric WatsonParticipantIf you have any questions please feel free to contact us.
Best Regards
November 12, 2019 at 5:22 pm #156581
horny_fungusParticipantOne more question.
I select variation A which has some gallery images, then I select variation B which has only main variation image and I see additional gallery images from variation A, not from parent product.
I think expected behaviour is to show gallery from parent product not previous variations?
To better understand:November 13, 2019 at 7:24 am #156651
Eric WatsonParticipantHello,
We created a product like yours and tested on you without a fix and everything works as well. The gallery is not replaced due to the fact that one of your variations has a gallery and the other does not, and if there is no gallery, only the main picture is replaced. Unfortunately, this is how our option of additional images works and we don’t have a quick solution to change the behavior.
Kind Regards
XTemos StudioNovember 13, 2019 at 11:23 am #156704
horny_fungusParticipantOK, got it. I hope you will consider implementing some solution to show only main image when there’s no gallery. Current implementation is rather misleading for costumer who has has every reason to think that the gallery pictures relate to current variation.
November 13, 2019 at 3:01 pm #156758
Eric WatsonParticipantYes, we will consult with our developers on the possibility of changing behavior.
Kind Regards
XTemos StudioNovember 26, 2019 at 7:34 am #158998
Artem TemosKeymasterHello,
After the latest update, you need to add also the following code to the functions.php in the child theme
add_filter( 'woodmart_sticky_product_details_offset', function () { return 100; } );
and put this to the Custom JS on document ready section
jQuery(window).on('main_gallery_replaced', function(){ fix_single_product(); }); fix_single_product(); function fix_single_product(){ if (!jQuery('.single-product-page').hasClass('product-sticky-on')) { return; } jQuery('.product-images-inner').imagesLoaded(function () { jQuery('.product-images-inner').css('min-height', jQuery('.woocommerce-product-gallery__wrapper').height()); }); }
Regards
November 26, 2019 at 10:55 am #159050
horny_fungusParticipantThank you. Can you please clarify what this code is doing and why it’s not introduced to everybody via recent update?
Everything related to single product page seems to be woring fine as is now (without adding thi code)November 26, 2019 at 12:14 pm #159089
Artem TemosKeymasterWe have customized the code in your core files. So if you update the theme, our fix will be lost and you will need to add it to the child theme as we sent you.
November 26, 2019 at 1:04 pm #159102
horny_fungusParticipantI’ve just double checked and found that my claim was wrong. Everything is not working fine but if I add only this code
add_filter( ‘woodmart_sticky_product_details_offset’, function () {
return 100;
} );everything seems to work fine without adding JS. Because of that I have a question what’s the purpose of this JS?
Also can you please clarify why this code is not added to core for everybody?November 27, 2019 at 1:05 pm #159104
Artem TemosKeymasterBecause this code is only to change the offset. It doesn’t fix anything but just set the offset size.
November 27, 2019 at 1:52 pm #159406
horny_fungusParticipantI don’t know why but scrolling works fine without this JS code.
Offset fix does the trick alone.November 27, 2019 at 2:12 pm #159427
Artem TemosKeymasterOK, great. Keep testing this and if you will face the problem again, just use our code.
-
AuthorPosts
- You must be logged in to create new topics. Login / Register