fbpx
Enjoy Year-End Sale: 50% Off All Plugins! Coupon Code: NewYear2025

Help with image change on color swatch selection – product page

Lisa Alpert

I have the plugin installed and configured.  I have two attributes, color and power. On the product page, the image changes correctly when the color swatch is selected, regardless of whether or not a power has been selected. So that’s all working as expected.

However, I want to disable product zoom and lightbox functionality from the product pages. The code I added to the functions.php file has accomplished that, but disabling the lightbox seems to also disable the image switch featured when selecting a color swatch.

This is the code I used to disable the lightbox feature, whereupon the image opens larger when clicked:

add_filter(‘woocommerce_single_product_image_thumbnail_html’,’wc_remove_link_on_thumbnails’ );
function wc_remove_link_on_thumbnails( $html ) {
return strip_tags( $html,'<img>’ );
}

Do you have a way for me to have both the image swap and the disabled lightbox?

Thank you!

Golam Kibria

Hi Lisa,

We apologize for the inconvenience.

Unfortunately, the shared credential did not work.

Please give us temporary admin access to your site.

We will investigate the issue for you.

You can use this plugin to create a passwordless temporary admin access link.

Once created, please share the link here.

Hope to hear from you soon.

Thank You

Lisa Alpert

My apologies. The same username/password I sent in the original ticket will work now.

And thank you for your speedy response. I expected an email notification when there was a reply and I just realized I should use the link to the ticket in the confirmation email to make sure I didn’t miss anything. Which I did.

I really appreciate any help you can provide.

Golam Kibria

Hi Lisa,

I hope that you are doing great. Thanks a lot for updating the information.

I have commented out the code in your child theme’s functions.php file.

To resolve the issue I have installed our gallery plugin on your site.

Please check this screencast.

We get excited & honored when you use our plugin on your site.

If you found my support helpful, could you leave your valuable review here: https://wordpress.org/support/plugin/woo-variation-swatches/reviews/?filter=5
(It would be nice if you mentioned your favorite feature in the review 🙂)

Your rating keeps us inspired 🎉️

Is there anything else we can do for you now?

Thanks a lot & have a great day

Lisa Alpert

Thank you very much! Looks and functions perfectly. I appreciate your help and will leave a positive review.

Golam Kibria

Hi Lisa,

Hopefully, you are doing fine.

I am glad that all the issues are resolved.

Please don’t forget to share a review.
(It would be nice if you mentioned your favorite feature in the review 🙂).

I wish you a great day.

Thank you