Video.js Jump Start PRO

Using the Video.js JavaScript library we can easily add video into our web page and do it in style. Video.js provides a common controls skin built in HTML/CSS, fixes cross-browser inconsistencies, adds additional features like fullscreen and subtitles and manages the fallback to Flash or to other playback technologies.

This video clip overviews a simple code sample for using the Video.js library. The code sample uses the very same video that Video.js developers use in their demo for this library so the credit belongs to them.

<!DOCTYPE html>
<html>
<head>
    <title>video.js sample</title>
    <link href="http://vjs.zencdn.net/4.0/video-js.css" rel="stylesheet">
    <script src="http://vjs.zencdn.net/4.0/video.js"></script>
</head>
<body>
<video id="ourvid" class="video-js vjs-default-skin"
        width="640" height="264"
       poster="http://video-js.zencoder.com/oceans-clip.png"
       data-setup='{"preload":true}'>
    <source src="http://video-js.zencoder.com/oceans-clip.mp4" type='video/mp4' />
    <source src="http://video-js.zencoder.com/oceans-clip.webm" type='video/webm' />
    <source src="http://video-js.zencoder.com/oceans-clip.ogv" type='video/ogg' />
</video>

<script type="text/javascript">
    var player = videojs("ourvid");
    player.ready(function(){
        this.play();
    }  )
</script>

</body>
</html>

You can find the community version of the Video.js Basics course available for free personal usage at http://abelski.lifemichael.com.

Share:

banner for the css playlist in hebrew life michael courses for programmers

The First Steps in CSS

Learn CSS using our our videos (in Hebrew) on the CSS (he) playlist on youtube. Do it now. Do it for free.

Good Trainers Collaborate with Others

It is always essential to keep an open mind and learn from others. This applies to everyone, including teachers and especially software development trainers. Software

The Beauty of Code

Coding is Art! Developing Code That Works is Simple. Develop Code with Style is a Challenge!

Update cookies preferences