powerful video player javascript code example

Example 1: best free html video player

<video id=”my-player” class=”video-js” controls preload=”auto” poster=”//vjs.zencdn.net/v/oceans.png” data-setup=’{}’> <source src=”//vjs.zencdn.net/v/oceans.mp4" type=”video/mp4"></source> <source src=”//vjs.zencdn.net/v/oceans.webm” type=”video/webm”></source> <source src=”//vjs.zencdn.net/v/oceans.ogv” type=”video/ogg”></source> <p class=”vjs-no-js”> To view this video please enable JavaScript, and consider upgrading to a web browser that <a href=”http://videojs.com/html5-video-support/” target=”_blank”> supports HTML5 video </a> </p></video>

Example 2: html5 video player

<video width="320" height="240" controls>
  <source src="movie.mp4" type="video/mp4">
  <source src="movie.ogg" type="video/ogg">
Your browser does not support the video tag. <!-- Text to be shown incase browser doesnt support html5 -->
</video>

Tags:

Html Example