[resolved] WooCommerce and Mobile Gallery (2 posts)

  1. Vynl
    Posted 3 years ago #

    I have installed WooCommerce on my site, and it works great.

    However I need a product gallery which works smoothly on mobile devices (and is touch responsive). The default Fancybox / lightbox doesn't reach the mark.

    I have installed the Mobile Gallery plugin on the site too and it works perfectly on regular pages. However it doesn't work on my WooCommerce product pages which is where I need it to work.

    How can I get it to use Mobile Gallery on these pages please?


  2. Vynl
    Posted 3 years ago #

    For anyone who has had the same problem, I fixed this by adding the following script to the theme itself (which in my case was in script.js in the /js folder). . .

    if ($ ('.product a').length ) {
    var wooCommercePhotoSwipe = $(".product").each(function(){
    $(this).find(".zoom").photoSwipe({ allowUserZoom:false, zIndex:'10000', captionAndToolbarShowEmptyCaptions:false });

    It works perfectly now. Hope this helps others.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WooCommerce
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic