Start a new topic

stuck

I am using Weebly builder for a website. I embeded the video and some photos as a testimony under the video. There is a HUGE space in between the video and the testimonies. On a desktop its fine. Its only on mobile that this large empty space shows up. They said it has something to do on Yuvids end. Could I get some help?
1 Comment

Hi Scoey,


Can you add CSS or Javascript with Weebly builder?


With CSS, you could add something like:


@media screen and (max-device-width:480px), screen and (max-width:480px) {

 #yuvid_wrapper {

       height: 270px;

 }

 #yuvid_iframe {

 height: 270px;

 }

}


With Javascript, you could add a function:


function autoResize(){

    var yuvidIframe = document.getElementById('yuvid_iframe');

    var width = yuvidIframe.offsetWidth;

    yuvidIframe.style.height = (width / 16 *9) + 'px' ;

    yuvidIframe.height = yuvidIframe.style.height ;

    document.getElementById('yuvid_wrapper').style.height = yuvidIframe.style.height;

}


To the page, and then add:

 

onload="autoResize();"

 

to the iframe tag. 


Login or Signup to post a comment