To display a youtube video in your web page, you have to use an id (like XGSy3_Czz8k) that will be displayed by the youtube when you save (or play or share) a video. You can use this id, and embed your video in the HTML code.
Following are the steps:
1. Play or share the video to YouTube
2. Note the video id generated by
youtube(like XGSy3_Czz8k)
3. In your html code define an iframe
element
4. Give the video URL to src attribute
5. Add the width and height attribute
to give the dimensions of the player
Example:
<!DOCTYPE html>
<html>
<body>
<iframe width="570" height="410"
src="http://www.youtube.com/embed/XGSy3_Czz8k">
</iframe>
</body>
</html>
0 Comment(s)