• The .png logo doesn’t appear in the site’s Age Gate. I’m not sure how far back it stopped working, but I have rolled back as far as 3.0.13 and it still isn’t appearing. I tried several things in CSS – forcing the image src in css, etc. – but nothing is changing for the better and have no idea what’s wrong.

    Here’s a screenshot of the code – it looks like the image source is getting overwritten: https://snipboard.io/sdzfth.jpg

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

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter dcbuffalo

    (@dcbuffalo)

    I also tried a .jpg file, that doesn’t show up either.

    Thread Starter dcbuffalo

    (@dcbuffalo)

    I looked on another site that we use this for (saratogaeagle.com) and it’s definitely just overriding the src=”” URL and adding a “data:image” code.

    Plugin Author Phil

    (@philsbury)

    Hi @dcbuffalo,

    This isn’t technically an age gate issue but your image optimiser. They often find images in the source and make them all lazy.

    Loos like your site has “EWW” doing lazyloading, so according to their documentation a class of skip-lazy will ignore an image.

    Need to get that on the age gate logo now, so add this to your functions:

    add_action('plugins_loaded', function() {
        age_gate_add_attribute('age-gate-logo', 'class', 'skip-lazy');
        age_gate_add_attribute('age-gate-logo', 'loading', 'lazy'); // this just adds native lazyloading
    });
    

    That should be that

    Thanks
    Phil

    Thread Starter dcbuffalo

    (@dcbuffalo)

    That code didn’t work (nothing happened), but thank you for pointing out the cause. I’m going to advocate on behalf of turning that plugin off – I have trained the client to pre-compress images anyway, so I doubt it is doing much of anything.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Age Gate Logo Not Appearing’ is closed to new replies.