Hello there,
I'm currently working on positioning the YouTube Iframe on the background to make it look like the video is playing on a laptop screen. I also want it to scale down appropriately with the background image on different resolutions.
The website has a width of 100% and the HTML code I'm using is:
<div class=youtube>
<div class=youtubesmaller>
<iframe width="100%" src="https://www.youtube.com/embed/videoseries?list=PLJdPTgbeDGN08yHg1Y46vzwDhj5Nxb-y_"
frameborder="0" allowfullscreen></iframe>
</div>
</div>
However, I noticed that the Iframe isn't scaling properly with the background-image on different resolutions, so I checked the CSS code:
/*music page stuff*/
.youtube {
background-image: url(http://breakline.nl/wp-content/uploads/2016/08/macbookframe.png?id=353) !important;
background-size: auto;
background-repeat: no-repeat;
background-position: right;
height: 600px;
}
.youtubesmaller {
width: 51.2%;
margin-left: 37.4%;
}
/*end music page stuff*/
Initially, I tried giving the Iframe a background, but later found out it wasn't possible.
Visit the website page