How do you insert a video in HTML?
Use the <video> tag for a video file, with the controls attribute to show the play button.
<video width="480" controls>
<source src="movie.mp4" type="video/mp4">
Your browser does not support the video tag.
</video>
For a YouTube video, use the embed code in an <iframe>.
<iframe width="560" height="315" src="https://www.youtube.com/embed/VIDEO_ID" title="Video" allowfullscreen></iframe>
See HTML5 Video and HTML Iframes.
Learn more about the similar topics:
| Tutorials |
|---|
| HTML Frames |
| HTML Iframes |
| HTML5 Introduction |
| HTML Multimedia |
| HTML5 Video |
| HTML5 Audio |
| HTML5 Canvas |
| Exercises & Assignments |
|---|
| No Content Found. |