• Hello,

    While on post format audio or video it seem not possible to embed more videos or audio in the content. The first video or audio from the post gets cloned and goes to the top of the single post and then the others dissapear due display: none on the video / audio iframes.

    Is there any way to fix this for audio and video post-format?

    Thank you,

Viewing 2 replies - 1 through 2 (of 2 total)
  • @dreamplango

    We will check on our development environment and if found the same issue then, we will probably fix that within theme update. So, thank you for your patience and understanding on it.

    Thanks.

    Thread Starter dreamplango

    (@dreamplango)

    Hello,

    I fixed the issue via CSS selectors and iframe / blocks classes (in this case for Gutenberg core/html blocks).

    I inverted the css display: none; to display: block; rule assigned to .entry-content iframe so all elements are visible.

    Then used a parent selector rule to display: none; the first iframe element of the content (or block). This way, I’m able to add more iframes / blocks to the rest of the content and not be limited to just one per post.

    Basically ALL elements are displayed in .entry-content but I want the first one to go away. You could of course assign the rule to the last one or anyone.

    I could have done it via jquery but this seemed easier to me. Also using a child theme. This is the code:

    .wp-block-emded: Gutenberg block by default for youtube and media embeds.

    .single-embed-top: first Core/xhtml block class assigned to the page, the one that s cloned to the top. The class was added via .js

    .single .format-video .entry-content figure.wp-block-embed,
    .single .format-audio .entry-content figure.single-embed-top {
    	display: none;
    }
    
    .single .format-audio .entry-content > figure.single-embed-top ~ figure.single-embed-top,
    .single .format-video .entry-content > figure.wp-block-embed ~ figure.wp-block-embed{
    	display: block;
    }

    Hope this help.

    Let me know if you guys are going to fix this in a next update so I’m aware of the changes or if I can help.

    Thanks,

    • This reply was modified 4 years, 7 months ago by dreamplango.
    • This reply was modified 4 years, 7 months ago by dreamplango.
    • This reply was modified 4 years, 7 months ago by dreamplango.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Audio post format not allow multiple video / audio embeds on entry-content?’ is closed to new replies.