HTML video not working

18,525

Video tag is not closed. Add autoplay if you want the video to play automatically.

 <!DOCTYPE html>
<html>
<head>
<title>video</title>
</head>
<body>
<video width="320" autoplay="autoplay" height="240" controls>
<source src="wildlife.mp4" type="video/mp4">
<source src="wildlife.ogg" type="video/ogg">
Your browser does not support the video tag.
</video>
</body>
</html>
Share:
18,525
Admin
Author by

Admin

Updated on June 04, 2022

Comments

  • Admin
    Admin almost 2 years

    I am trying to get a video to play locally but it isn't working. the file is 'wildlife.mp4,' however, it doesn't play it is just a blank video box? Any help will be much appreciated, thanks.

    <!DOCTYPE html>
    <html>
    <head>
    <title>video</title>
    </head>
    <body>
    <video width="320" height="240" controls>
    <source src="wildlife.mp4" type="video/mp4">
    <source src="wildlife.ogg" type="video/ogg">
    Your browser does not support the video tag.
    </body>
    </html>
    

    enter image description here