• yankiara

    (@yankiara)


    Hi Gijo,

    First, congratulations for Flying Images which is an awesome plugin. Could never find any better lazy load tool so far ??

    Nevertheless, it seems it doesn’t handle <picture><source></picture> well: all <source> tags disappear.

    Besides, and this is more serious, it looks like it happens even when excluding picture or img tags from lazy-load (for instance with a class on picture or img or parent).

    I might be missing something, though.

    Here is an example:

    
    <picture class="ma-gdpr-youtube-thumbnail"><source media="(min-width:640px)" srcset="imgxxxxx.jpg"><source media="(min-width:320px)" srcset="imgxxxxx.jpg"><source media="(min-width:240px)" srcset="imgxxxxx.jpg"><img alt="Alt text" src="imgxxxxx.jpg"></picture>
    

    And here is the result:

    
    <picture class="ma-gdpr-youtube-thumbnail"><img alt=Alt text" src="imgxxx.jpg"></picture>
    

    So is the plugin supposed to work with this these tags?
    If so, what am I doing wrong?

    Thanks in advance ??

Viewing 1 replies (of 1 total)
  • Thread Starter yankiara

    (@yankiara)

    OK, I’ve just noticed that in html-rewrite.php:

    
            // Remove picture tag
            foreach ($newHtml->find('picture') as $picture) {
                $picture->innertext = $picture->find('img', 0);
            }
    

    Is there a specific reason you remove picture tags?

    Also note that this code is executed WITHOUT CONDITION, even if lazy-load is disabled!!!

    So the only way to prevent this is to completely deactivate plugin ??

    • This reply was modified 2 years, 8 months ago by yankiara.
    • This reply was modified 2 years, 8 months ago by yankiara.
    • This reply was modified 2 years, 8 months ago by yankiara.
Viewing 1 replies (of 1 total)
  • The topic ‘picture/source/img tags’ is closed to new replies.