how to change video Embed size in blogger. Creating a responsive YouTube embed.

if you want to make a responsive youtube Embeded code then, you can use this technique with most other iframe based code. which need you to give it a certain aspect ratio.
Creating a responsive YouTube embed.

when you copy embed code of any youtube videos then, you get the YouTube embed code with fixed width and height. It looks like below given code.


<iframe width="760" height="428" src="https://www.youtube.com/embed/M_k85ruRE4w" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

how to change video Embed size in blogger. Creating a responsive YouTube embed.

When we give it 100% width and height, then it will give you bydefault result. which is small and it not responsive. Now we need to fix to properly. which give auto Width and height according to your window size.
you can solve this problem by using this tips. copy this below given HTML code And CSS Code.

how to change video Embed size in blogger. Creating a responsive YouTube embed.

if you are using blogger then you need to login in blogger go to "Theme", select "Customize", select "Add CSS", paste CSS code there.
HTML Container will be in your post, where you want show this YouTube Video in your Post.
Remember you will need to delete fixed (width="760" height="428" ). or you can use as its. and replace video "ID" which highlighted in red color.

Youtube Embed HTML Code


<div class = "ytresponsive">

<iframe src = "https://www.youtube.com/embed/M_k85ruRE4w" frameborder = "0" allowable screen class = "video"> </ iframe>

</ div>

YouTube Embed CSS code


<style>

.ytresponsive {Status: Relative; Width: 100%; Height: 0; Padding-bottom: 56.25%; }

.Video {Status: Absolute; Top: 0; Left: 0; Width: 100%; Height: 100%; }

</style>
if first method is not working then do it. it's work with Blogger blog.

how to change video Embed size in blogger.


<style>.embed-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; max-width: 100%; } .embed-container iframe, .embed-container object, .embed-container embed { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }</style><div class='embed-container'><iframe src='https://www.youtube.com/embed/M_k85ruRE4w' frameborder='0' allowfullscreen></iframe></div>

Here's the Youtube Embed code result-



embed codeyoutube urlyoutube websiteembed videoyoutube embedyoutube playeryoutubeyoutube generatoryoutube siteyoutube htmlyoutube codelink youtubeyoutube linkget link youtubeyoutube clipembed youtube videovideo embed codewww youtubeyoutube embed optionsyoutube embed code generatoryoutube html codeyoutube pagevideo urlyoutube aembedded video playercode youtubeyoutube web pageyoutube video playeryoutube embed generatoryoutube embed linkvideo embed code generatorwwws youtubehtml video codeyoutube embedded player generatoryoutube embed urlyoutube link generatorembed video onlineembed youtube html

if you want to make a responsive youtube Embeded code then, you can use this technique with most other iframe based code. which need you to give it a certain aspect ratio. Creating a responsive YouTube embed. when you copy embed code of any youtube videos then, you get the YouTube embed code with fixed width and height. It looks like below given code. <iframe width="760" height="428" src="https://www.youtube.com/embed/M_k85ruRE4w" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe> When we give it 100% width and height, then it will give you bydefault result. which is small and it not responsive. Now we need to fix to properly. which give auto Width and height according to your window size. you can solve this problem by using this tips. copy this below given HTML code And CSS Code. if you are using blogger then you need to login in blogger go to "Theme", select "Customize", select "Add CSS", paste CSS code there. HTML Container will be in your post, where you want show this YouTube Video in your Post. Remember you will need to delete fixed (width="760" height="428" ). or you can use as its. and replace video "ID" which highlighted in red color. HTML <div class = "ytresponsive"> <iframe src = "https://www.youtube.com/embed/M_k85ruRE4w" frameborder = "0" allowable screen class = "video"> </ iframe> </ div> CSS: <style> .ytresponsive {Status: Relative; Width: 100%; Height: 0; Padding-bottom: 56.25%; } .Video {Status: Absolute; Top: 0; Left: 0; Width: 100%; Height: 100%; } </style> if first method is not working then do it. it's work with Blogger blog. how to change video Embed size in blogger. <style>.embed-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; max-width: 100%; } .embed-container iframe, .embed-container object, .embed-container embed { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }</style><div class='embed-container'><iframe src='https://www.youtube.com/embed/M_k85ruRE4w' frameborder='0' allowfullscreen></iframe></div> Here's the Youtube Embed code result- embed codeyoutube urlyoutube websiteembed videoyoutube embedyoutube playeryoutubeyoutube generatoryoutube siteyoutube htmlyoutube codelink youtubeyoutube linkget link youtubeyoutube clipembed youtube videovideo embed codewww youtubeyoutube embed optionsyoutube embed code generatoryoutube html codeyoutube pagevideo urlyoutube aembedded video playercode youtubeyoutube web pageyoutube video playeryoutube embed generatoryoutube embed linkvideo embed code generatorwwws youtubehtml video codeyoutube embedded player generatoryoutube embed urlyoutube link generatorembed video onlineembed youtube html

Comments