Support » Plugin: Photonic Gallery & Lightbox for Flickr, SmugMug, Google Photos & Others » Plugin load all the pictures twice with flickr

  • Resolved Elano

    (@elano)


    Hello,
    I have a problem with the plugin everytime I click on the “more” button all the pictures are loaded twice… I show 14 pictures and when you click on the “More” button it loads 28 pictures always the 14 pictures but twice.

    Justified grid is loaded twice in the console.

    I use Colorbox as the lightbox because most of theme doesn’t work or have the same problem loading the pictures twice.

    For the layout processing I use PhP and CSS because JS doesn’t work it won’t show any pictures or show the pictures but I can’t change their size.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Sayontan Sinha

    (@sayontan)

    You have a problem with your caching plugin. Standard Photonic setup includes two lines of JS files:

    <script nomodule src='https://.../nomodule/.../photonic-....min.js?ver=...'></script>
    <script type='module' src='https://.../module/.../photonic-....min.js?ver='></script>

    If you are using an old browser, the first line of code is used and the second is ignored. If you are using a new browser, the second line of code is used and the first is ignored.

    But your caching plugin has combined both scripts into one. This is problematic because on new browsers it will execute the code twice (which is what you are seeing), and on old browsers your code will completely fail.

    The solution is to remove Photonic’s JS files from the scope of your caching plugin.

    I use Colorbox as the lightbox because most of theme doesn’t work or have the same problem loading the pictures twice.

    You might have picked Colorbox in Photonic, but what you are getting is not Colorbox. You are getting Elementor’s lightbox. This might look fine, but it causes different types of issues that are not visible. E.g. you will not be able to see titles in your photos and a lot of other things which work perfectly with Photonic will not work. Also, this can cause two lightboxes to pop up.

    For this you will need to either disable Elementor’s lightbox, or work with their support team to figure out how to exclude Photonic’s photos from Elementor’s lightbox (just like how Photonic does not try apply its lightbox to other photos unless you ask it to do so).

    Thread Starter Elano

    (@elano)

    Thank you for the fast answers working fine now

    The problem was because W3 Total cache combined and minified the JS files 🙂

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.