WordPress.org

Ready to get started?Download WordPress

Forums

Lazy Load for Videos
Plugin does not work when using the youtube embed code from youtube (4 posts)

  1. dpaq2011
    Member
    Posted 1 year ago #

    Hi Kevin,
    this plugin is a terrific idea, so well done for working on it.

    I can see the plugin clearly working when adding this to the post:

    http://www.youtube.com/watch?v=dQw4w9WgXcQ

    However if I add the embed code from youtube:

    <iframe width="420" height="315" src="//www.youtube.com/embed/dQw4w9WgXcQ" frameborder="0" allowfullscreen></iframe>

    Then it does not work. Sometimes we need to add this code because we want to play with video settings (captions on/off, etc.).

    Is there a way the plugin works with the iframe, or is this completely out of scope?

    Thank you

    http://wordpress.org/plugins/lazy-load-for-videos/

  2. kevinweber
    Member
    Plugin Author

    Posted 11 months ago #

    Hi,

    your Iframe Code is not working with the plugin, you're right. This kind of embedding is not supported and isn't going to be supported anytime soon.

    Maybe you can add some parameters directly to your Youtube URL, like this:
    http://www.youtube.com/watch?v=dQw4w9WgXcQ&parameter=value

    Regards,

    Kevin

  3. fgordilloz
    Member
    Posted 7 months ago #

    But when I need different youtube sizes in posts or pages, no other option: iframe or shortcode. And with this options, your plugin don't work.

    Any solution?

    Thanks.

  4. kevinweber
    Member
    Plugin Author

    Posted 7 months ago #

    You can do the following:
    Add enclosing tags with custom CSS code. But it's important that you add the YouTube link on its own line.

    <div style="width:200px;">
    http://www.youtube.com/watch?v=IJNR2EpS0jw
    </div>

    What do you think of this solution?

    Regards,

    Kevin

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.