• Resolved paulknorrnl

    (@paulknorrnl)


    Hai all, when I add a link to een Vimeo movie in de post this is not the 100% width. Is there any change to change this to 100% width automatically?

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

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Wayne Allen

    (@wayneallen-1)

    You might try https://postieplugin.com/downloads/fix-video-links/

    But ultimately it.may depend on your theme.

    Thread Starter paulknorrnl

    (@paulknorrnl)

    I fixed it with with a small Java script, thnx anyway!

    Plugin Author Wayne Allen

    (@wayneallen-1)

    Nice solution. Can you share for others?

    Thread Starter paulknorrnl

    (@paulknorrnl)

    Of course, we are here to help each other. This script is written based on the Vimeo platform!

    <script>
    function adjustIframe() {
        var vimeoIframe = document.querySelector('iframe[src*="vimeo.com"]');
        if (vimeoIframe) {
            vimeoIframe.style.width = '100%';
            var aspectRatio = vimeoIframe.height / vimeoIframe.width;
            vimeoIframe.style.height = (vimeoIframe.offsetWidth * aspectRatio) + 'px';
        }
    }
    
    window.addEventListener('load', adjustIframe);
    window.addEventListener('resize', adjustIframe);
    </script>
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Video in post full width’ is closed to new replies.