1
0
mirror of https://github.com/videojs/video.js.git synced 2024-11-28 08:58:46 +02:00

Merge branch 'master' of github.com:videojs/video.js

This commit is contained in:
Steve Heffernan 2014-02-10 16:09:32 -08:00
commit 49656ab013

View File

@ -86,3 +86,17 @@ The second argument is an options object. It allows you to set additional option
The third argument is a 'ready' callback. Once Video.js has initialized it will call this function.
Instead of using an element ID, you can also pass a reference to the element itself.
```js
videojs(document.getElementsById('example_video_1')), {}, function()) {
// This is functionally the same as the previous example.
});
```
```js
videojs(document.getElementsByClassName('awesome_video_class')[0], {}, function()) {
// You can grab an element by class if you'd like, just make sure
// if it's an array that you pick one (here we chose the first).
});
```