htmlvideo

HTML5 Video // Completely Hide Controls


How Could I completely hide HTML5 video controls?

<video width="300" height="200" controls="false" autoplay="autoplay">
<source src="video/supercoolvideo.mp4" type="video/mp4" />
</video> 

false didn't work -- how is this done?

Cheers.


Solution

  • Like this:

    <video width="300" height="200" autoplay="autoplay">
      <source src="video/supercoolvideo.mp4" type="video/mp4" />
    </video>
    

    controls is a boolean attribute:

    Note: The values "true" and "false" are not allowed on boolean attributes. To represent a false value, the attribute has to be omitted altogether.