How to Embed a Video in HTML

How-to-Embed-a-Video-in-HTML

In HTML5, you can embed a video in your Website using a pair of <video> tags. It is also mandatory to define the <source> Tags for the video.

<video width="400" height="300">
  <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
  <source src="Enter-Your-Video-Path.webm" type="video/webm">
  <source src="Enter-Your-Video-Path.ogg" type="video/ogg">
  Video tag is not supported in this browser.
</video>

1. Add Height And Width

<video width="400" height="300">
     <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
</video>

2. Add Fullscreen

<video width="100%" height="300">
    <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
</video>

3. Add Video Player Controls

<video controls="controls" width="100%" height="300">
    <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
</video>

4. Add Image Your Video

<video poster="Enter-Your-Image-Path" controls="controls" width="100%" height="300">
    <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
</video>

5. Add Video Autoplay

<video poster="Enter-Your-Image-Path" autoplay="autoplay" controls="controls" width="100%" height="300">
    <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
</video>

6. Add Video Looping

<video poster="Enter-Your-Image-Path" loop="loop" autoplay="autoplay" controls="controls" width="100%" height="300">
    <source src="Enter-Your-Video-Path.mp4" type="video/mp4">
</video>
We Well organized and easy-to-understand Interactive tutorials With lots of examples of how to use Tutorials WordPress, PHP, Bootstrap, Bootstrap 4, HTML, CSS, AJAX, jQuery, Woocommerce, Post, Database, Javascript, Theme, Responsive, Templates.

Leave a Reply

Your email address will not be published. Required fields are marked *

Contact us

Fill in the form below or give us a call and we'll contact you. We endeavour to answer all enquiries within 24 hours on business days.