Google YouTube API blog introduced a new way to embed youtube videos. An enhancement to our video embed capability is now available through a new embed code style. This new style uses <iframe> and looks like this:
Here's an example of embed code:
<iframe class="youtube-player" type="text/html" width="640" height="385" src="http://www.youtube.com/embed/VIDEO_ID" frameborder="0">
</iframe>
Change with your VIDEO_ID, additionally you can change the height and width also.
New embedded style videos can view on Flash or HTML5 players, If HTML5 isn't supported it will use Flash. Also new embed style allow embeds to work on mobile devices, which typically use a built-in player instead of Flash or HTML5.
0 comments:
Post a Comment