Example
Get the kind of text track:
var x = document.getElementById("myTrack").kind;
The result of x could be:
subtitles
Definition and Usage
The kind property sets or returns the value of the kind attribute of the track.
The kind attribute specifies the kind of text track.
Browser Support
The kind property is supported Internet Explorer, Opera, and Chrome.
Note: The kind property is not supported in Firefox, Safari or Internet Explorer 9 and earlier versions.
Syntax
Return the kind property:
trackObject.kind
Set the kind property:
trackObject.kind="captions|chapters|descriptions|metadata|subtitles"
Property Values
Value | Description |
---|---|
captions | The track defines translation of dialogue and sound effects (suitable for deaf users) |
chapters | The track defines chapter titles (suitable for navigating the media resource) |
descriptions | The track defines a textual description of the video content (suitable for blind users) |
metadata | The track defines content used by scripts. Not visible for the user |
subtitles | The track defines subtitles, used to display subtitles in a video |
Technical Details
Return Value: | A String, representing the kind of text track |
---|
More Examples
Example
Set the kind of text track:
document.getElementById("myTrack").kind = "chapters";
Related Pages
HTML reference: HTML <track> kind attribute
< Track Object